[pLog-svn] r3244 - plugins/trunk
oscar at devel.lifetype.net
oscar at devel.lifetype.net
Wed Apr 12 20:35:38 GMT 2006
Author: oscar
Date: 2006-04-12 20:35:38 +0000 (Wed, 12 Apr 2006)
New Revision: 3244
Modified:
plugins/trunk/moblog.php
Log:
changes made before were not necessary, since authenticateUser only returns a boolean and not a UserInfo object. Now the plugin should work again.
Modified: plugins/trunk/moblog.php
===================================================================
--- plugins/trunk/moblog.php 2006-04-12 20:04:16 UTC (rev 3243)
+++ plugins/trunk/moblog.php 2006-04-12 20:35:38 UTC (rev 3244)
@@ -72,8 +72,10 @@
// first, try to authenticate the user
//
$users = new Users();
- $userInfo = $users->authenticateUser( $request->getUser(), $request->getPassword());
- if( !$userInfo ) {
+ if( $users->authenticateUser( $request->getUser(), $request->getPassword())) {
+ $userInfo = $users->getUserInfoFromUsername( $request->getUser());
+ }
+ else {
$response = new MoblogResponse( $request->getReplyTo(),
"pLog Moblog: Error",
"User or password are not correct."
@@ -145,7 +147,7 @@
//
// now check if the user has permissions over the blog
//
- $userPermissions = new UserPermissions();
+$userPermissions = new UserPermissions();
$userPerm = $userPermissions->getUserPermissions( $userInfo->getId(), $blogInfo->getId());
if( !$userPerm ) {
$response = new MoblogResponse( $request->getReplyTo(),
More information about the pLog-svn
mailing list