DataObjects/Core_curr_rate.php
[Pman.Core] / DataObjects / Person.php
index 6dc1356..471ac33 100644 (file)
@@ -377,11 +377,12 @@ class Pman_Core_DataObjects_Person extends DB_DataObject
         if (!empty($_SESSION[get_class($this)][$sesPrefix .'-auth'])) {
             $a = unserialize($_SESSION[get_class($this)][$sesPrefix .'-auth']);
             
-            
             $u = DB_DataObject::factory($this->tableName()); // allow extending this ...
             $u->autoJoin();
             if ($u->get($a->id)) { /// && strlen($u->passwd)) {  // should work out the pid .. really..
-                return clone($u);
+                $user = clone ($u);
+                
+                return clone($user);
             }
             unset($_SESSION[get_class($this)][$sesPrefix .'-auth']);
         }
@@ -454,9 +455,6 @@ class Pman_Core_DataObjects_Person extends DB_DataObject
         
         $d = $p->toArray();
         
-        if(!empty($this->_extra) && is_array($this->_extra)){
-            $d = array_merge($d, $this->_extra);
-        }
         //var_dump(array(get_class($this),$sesPrefix .'-auth'));
         $_SESSION[get_class($this)][$sesPrefix .'-auth'] = serialize((object)$d);
         // ensure it's written so that ajax calls can fetch it..