[pLog-svn] r3673 - plog/trunk/class/action/admin

mark at devel.lifetype.net mark at devel.lifetype.net
Fri Jun 30 10:37:52 GMT 2006


Author: mark
Date: 2006-06-30 10:37:51 +0000 (Fri, 30 Jun 2006)
New Revision: 3673

Modified:
   plog/trunk/class/action/admin/adminloginaction.class.php
Log:
We need to modify the userInfo after we check all validations and situation. Or the userInfo will change to the new user even the user still disable and can not login.

Modified: plog/trunk/class/action/admin/adminloginaction.class.php
===================================================================
--- plog/trunk/class/action/admin/adminloginaction.class.php	2006-06-30 05:57:23 UTC (rev 3672)
+++ plog/trunk/class/action/admin/adminloginaction.class.php	2006-06-30 10:37:51 UTC (rev 3673)
@@ -84,14 +84,7 @@
 			}
 			
 			$pm->notifyEvent( EVENT_USER_LOADED, Array( "user" => &$userInfo, "from" => "Login" ));
-            //$sessionInfo = $_SESSION["SessionInfo"];
-            $session = HttpVars::getSession();
-            $sessionInfo = $session["SessionInfo"];
 
-            $sessionInfo->setValue( "userInfo", $userInfo );
-            $session["SessionInfo"] = $sessionInfo;
-            HttpVars::setSession( $session );
-
             // get the list of blogs to which the user belongs
             $userBlogs = $users->getUsersBlogs( $userInfo->getId(), BLOG_STATUS_ACTIVE );
 
@@ -103,6 +96,14 @@
 
                 return false;
             }
+
+            // We have to update the userInfo in session after we check all situations
+            $session = HttpVars::getSession();
+            $sessionInfo = $session["SessionInfo"];
+
+            $sessionInfo->setValue( "userInfo", $userInfo );
+            $session["SessionInfo"] = $sessionInfo;
+            HttpVars::setSession( $session );
 			
 			$pm->notifyEvent( EVENT_BLOGS_LOADED, Array( "blogs" => &$userBlogs, "from" => "Login" ));			
 			



More information about the pLog-svn mailing list