Commits

Anonymous committed 43f68f5

Fix for CACHE-88

  • Participants
  • Parent commits 312e0e1

Comments (0)

Files changed (1)

src/core/java/com/opensymphony/oscache/web/tag/CacheTag.java

         }
 
         // Retrieve the cache
-        cache = admin.getCache((HttpServletRequest) pageContext.getRequest(), scope);
+        if (scope == PageContext.SESSION_SCOPE) {
+            cache = admin.getSessionScopeCache(((HttpServletRequest) pageContext.getRequest()).getSession(true));
+        } else {
+            cache = admin.getAppScopeCache(pageContext.getServletContext());
+        }
 
         // This allows to have multiple cache tags on a single page without
         // having to specify keys. However, nested cache tags are not supported.