[pLog-svn] r1019 - plog/trunk/class/action/admin
oscar at devel.plogworld.net
oscar at devel.plogworld.net
Wed Feb 9 07:43:58 GMT 2005
Author: oscar
Date: 2005-02-09 07:43:57 +0000 (Wed, 09 Feb 2005)
New Revision: 1019
Modified:
plog/trunk/class/action/admin/adminmainaction.class.php
Log:
fixed an indentation issue (!!??)
Modified: plog/trunk/class/action/admin/adminmainaction.class.php
===================================================================
--- plog/trunk/class/action/admin/adminmainaction.class.php 2005-02-09 07:12:41 UTC (rev 1018)
+++ plog/trunk/class/action/admin/adminmainaction.class.php 2005-02-09 07:43:57 UTC (rev 1019)
@@ -33,8 +33,8 @@
*/
function validate()
{
- // first of all, check if we have a valid blog id
- $this->_blogId = $this->_request->getValue( "blogId" );
+ // first of all, check if we have a valid blog id
+ $this->_blogId = $this->_request->getValue( "blogId" );
if( $this->_blogId == "" || $this->_blogId < 0 ) {
// check if the user really belongs to one or more blogs and if not, quit
@@ -52,35 +52,35 @@
return false;
}
- // load the blog
- $blogs = new Blogs();
- $this->_blogInfo = $blogs->getBlogInfo( $this->_blogId );
+ // load the blog
+ $blogs = new Blogs();
+ $this->_blogInfo = $blogs->getBlogInfo( $this->_blogId );
- // check if the blog really exists
- if( !$this->_blogInfo ) {
+ // check if the blog really exists
+ if( !$this->_blogInfo ) {
$this->_view = new AdminSimpleErrorView();
$this->_view->setValue( "message", $this->_locale->tr("error_incorrect_blog_id" ));
return false;
- }
+ }
// if the blog identifier is valid, now we should now check if the user belongs
// to that blog so that we know for sure that nobody has tried to forge the
// parameter in the meantime
- $userPermissions = new UserPermissions();
- $blogUserPermissions = $userPermissions->getUserPermissions( $this->_userInfo->getId(), $this->_blogInfo->getId());
- if( !$blogUserPermissions ) {
+ $userPermissions = new UserPermissions();
+ $blogUserPermissions = $userPermissions->getUserPermissions( $this->_userInfo->getId(), $this->_blogInfo->getId());
+ if( !$blogUserPermissions ) {
$this->_view = new AdminSimpleErrorView();
$this->_view->setValue( "message", $this->_locale->tr("error_no_permissions" ));
return false;
- }
+ }
- // if all correct, we can now set the blogInfo object in the session for later
- // use
- $session = HttpVars::getSession();
- $session["SessionInfo"]->setValue( "blogInfo", $this->_blogInfo );
- HttpVars::setSession( $session );
+ // if all correct, we can now set the blogInfo object in the session for later
+ // use
+ $session = HttpVars::getSession();
+ $session["SessionInfo"]->setValue( "blogInfo", $this->_blogInfo );
+ HttpVars::setSession( $session );
return true;
}
More information about the pLog-svn
mailing list