Index: branches/unlabeled/unlabeled-1.60.2/kernel/units/users/users_event_handler.php =================================================================== diff -u -r5414 -r5428 --- branches/unlabeled/unlabeled-1.60.2/kernel/units/users/users_event_handler.php (.../users_event_handler.php) (revision 5414) +++ branches/unlabeled/unlabeled-1.60.2/kernel/units/users/users_event_handler.php (.../users_event_handler.php) (revision 5428) @@ -104,8 +104,7 @@ */ function OnLogin(&$event) { - $this->Application->setUnitOption($event->Prefix, 'AutoLoad', false); - $object =& $this->Application->recallObject('u'); + $object =& $this->Application->recallObject('u', null, Array('skip_autoload' => true)); $password = $this->Application->GetVar('password'); if(!$password) @@ -451,7 +450,6 @@ $object =& $event->getObject( Array('skip_autoload' => true) ); $this->Application->SetVar('u_id', $object->getID() ); - $this->Application->setUnitOption('u', 'AutoLoad', true); $this->setNextTemplate($event); @@ -470,8 +468,7 @@ */ function setUserStatus(&$event) { - $this->Application->setUnitOption($event->Prefix,'AutoLoad',false); - $object =& $event->getObject(); + $object =& $event->getObject( Array('skip_autoload' => true) ); $new_users_allowed = $this->Application->ConfigValue('User_Allow_New'); // 1 - Instant, 2 - Not Allowed, 3 - Pending @@ -587,8 +584,7 @@ */ function OnUpdateAddress(&$event) { - $this->Application->setUnitOption($event->Prefix,'AutoLoad',false); - $object =& $event->getObject(); + $object =& $event->getObject( Array('skip_autoload' => true) ); $items_info = $this->Application->GetVar( $event->getPrefixSpecial(true) ); if($items_info) @@ -607,10 +603,9 @@ $user_email = $this->Application->GetVar('subscriber_email'); if ( preg_match("/^[_a-zA-Z0-9-\.]+@[a-zA-Z0-9-\.]+\.[a-z]{2,4}$/", $user_email) ){ + + $object = &$this->Application->recallObject($this->Prefix.'.subscriber', null, Array('skip_autoload' => true)); - $this->Application->setUnitOption($event->Prefix,'AutoLoad',false); - $object = &$this->Application->recallObject($this->Prefix.'.subscriber'); - $this->Application->StoreVar('SubscriberEmail', $user_email); if( $object->Load(array('Email'=>$user_email)) ){ @@ -643,8 +638,7 @@ function OnSubscribeUser(&$event){ - $this->Application->setUnitOption($event->Prefix,'AutoLoad',false); - $object = &$this->Application->recallObject($this->Prefix.'.subscriber'); + $object = &$this->Application->recallObject($this->Prefix.'.subscriber', Array('skip_autoload' => true)); $user_email = $this->Application->RecallVar('SubscriberEmail'); @@ -735,8 +729,7 @@ function OnForgotPassword(&$event){ - $this->Application->setUnitOption('u', 'AutoLoad', false); - $user_object = &$this->Application->recallObject('u.forgot'); + $user_object = &$this->Application->recallObject('u.forgot', null, Array('skip_autoload' => true)); $user_current_object = &$this->Application->recallObject('u'); $username = $this->Application->GetVar('username');