Re: Re: Liveuser - can't create auth container instance
| From: | Jeroen Houben | Date: | Wed, 31 Aug 2005 11:57:31 +0000 |
| Subject: | Re: Re: Liveuser - can't create auth container instance | ||
| References: | 1 2 3 4 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-20686@lists.php.net to get a copy of this message | ||
Lukas Smith wrote:
Jeroen Houben wrote:So if I would use the perm and the auth part, it would be better to call the methods directly on the $lu_admin object. Anyway, it works now, time to start adding some users. Thanks again! JeroenYes, I see. I'm slowly beginning to grasp the concepts :-) There are no users defined yet, I get an exception when runnig $lu_admin->getUsers(). Again, I feel an exception is not needed, simple returning an empty array makes more sense to me. It's like querying a database, returning 0 rows is by no means an exception. Or am I overlooking something?The point is. LiveUser_Admin is a wrapper class. It loads the admin aith and perm container instances and unifies a few methods that deal with user management. The actual work is done inside the admin auth or perm container instances. So if you only use the perm part, then most of the methods inside LiveUser_Admin are not relevant to you. Instead call $LU->perm->getUsers() instead.