svn: /web/doc-editor/trunk/php/ AccountManager.php

From: Date: Sat, 23 Jul 2011 09:27:15 +0000
Subject: svn: /web/doc-editor/trunk/php/ AccountManager.php
Groups: php.doc.web 
Request: Send a blank email to doc-web+get-2148@lists.php.net to get a copy of this message
yannick Sat, 23 Jul 2011 09:27:15 +0000 Revision: http://svn.php.net/viewvc?view=revision&revision=313626 Log: Fix bug when this is an anymous user to enter into this function Changed paths: U web/doc-editor/trunk/php/AccountManager.php Modified: web/doc-editor/trunk/php/AccountManager.php =================================================================== --- web/doc-editor/trunk/php/AccountManager.php 2011-07-23 09:02:07 UTC (rev 313625) +++ web/doc-editor/trunk/php/AccountManager.php 2011-07-23 09:27:15 UTC (rev 313626) @@ -491,10 +491,12 @@ $params = array($this->project, $userLogin, $anonymousIdent); $r = $this->conn->query($s, $params); $a = $r->fetch_object(); + + // An anonymous have is #xxx at the end of his login. So, the sql "failed" + if( !is_object($a) ) { + return true; + } - // We have a warn in production here - debug("In AccountManager ; In anonymous() method ; userLogin=".$userLogin."; anonymousIdent=".$anonymousIdent.";"); - return ( $a->authService == 'VCS' && $a->anonymousIdent == '' ) ? false : true; }

« previous php.doc.web (#2148) next »