From: Richard S. <ri...@ri...> - 2003-12-03 11:57:16
|
I don't know about you guys but this is the way my constructor looks like for the PHPWS_User_Groups class in the User mod. If you notice you'll see that the $members variable is erased if it got or didn't get the information and I was just wondering if that made sense? The alternative is just to use the loadGroup function after the constructor which makes it 2 steps to get the group information. function PHPWS_User_Groups($group_id=NULL){ if (isset($group_id) && is_numeric($group_id)) if (!$this->loadGroup($group_id)) $this->members=array(); else $this->members=array(); } |