Created
April 16, 2010 10:50
-
-
Save co3k/368279 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/lib/user/opSecurityUser.class.php b/lib/user/opSecurityUser.class.php | |
index 60e6e45..679a889 100644 | |
--- a/lib/user/opSecurityUser.class.php | |
+++ b/lib/user/opSecurityUser.class.php | |
@@ -18,6 +18,8 @@ | |
*/ | |
class opSecurityUser extends opAdaptableUser | |
{ | |
+ protected $serializedMember = null; | |
+ | |
/** | |
* Initializes the current user. | |
* | |
@@ -47,6 +49,17 @@ class opSecurityUser extends opAdaptableUser | |
return new opAnonymousMember(); | |
} | |
+ if ($this->serializedMember) | |
+ { | |
+ return unserialize($this->serializedMember); | |
+ } | |
+ | |
+ $result = Doctrine::getTable('Member')->find($this->getMemberId()); | |
+ | |
+ $this->serializedMember = serialize($result); | |
+ | |
+ return $result; | |
+ | |
if ($inactive) | |
{ | |
return Doctrine::getTable('Member')->findInactive($this->getMemberId()); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment