Let user cache have the user prototype and dbmapping so
collections/virtual subnodes work for anonymous users.
This commit is contained in:
parent
dee820e805
commit
e9aa7b7edd
1 changed files with 4 additions and 2 deletions
|
@ -45,8 +45,8 @@ public class User implements Serializable {
|
||||||
setNode (null);
|
setNode (null);
|
||||||
umap = app.getDbMapping ("user");
|
umap = app.getDbMapping ("user");
|
||||||
cache = new TransientNode ("[session cache]");
|
cache = new TransientNode ("[session cache]");
|
||||||
// cache.setPrototype ("user");
|
cache.setPrototype ("user");
|
||||||
// cache.setDbMapping (umap);
|
cache.setDbMapping (umap);
|
||||||
sessionID = sid;
|
sessionID = sid;
|
||||||
onSince = System.currentTimeMillis ();
|
onSince = System.currentTimeMillis ();
|
||||||
lastTouched = onSince;
|
lastTouched = onSince;
|
||||||
|
@ -127,6 +127,8 @@ public class User implements Serializable {
|
||||||
*/
|
*/
|
||||||
public void clearCache () {
|
public void clearCache () {
|
||||||
cache = new TransientNode ("[session cache]");
|
cache = new TransientNode ("[session cache]");
|
||||||
|
cache.setPrototype ("user");
|
||||||
|
cache.setDbMapping (umap);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue