From: xzilla Date: Wed, 10 Aug 2005 18:34:06 +0000 (+0000) Subject: I believe this is a bug. Even if getPrivileges returns -1, if you do a sizeof on... X-Git-Tag: REL_3-5-5~5 X-Git-Url: http://git.postgresql.org/gitweb/?a=commitdiff_plain;h=0e77fff763c3c81fd9d40e0b17b357ad53d75799;p=phppgadmin.git I believe this is a bug. Even if getPrivileges returns -1, if you do a sizeof on $privileges you will allways get back > 0. I intend to change this in HEAD unless someone has a counter argument. --- diff --git a/privileges.php b/privileges.php index 78295bb9..e0de967a 100644 --- a/privileges.php +++ b/privileges.php @@ -3,7 +3,7 @@ /** * Manage privileges in a database * - * $Id: privileges.php,v 1.34.2.1 2004/12/08 13:50:40 chriskl Exp $ + * $Id: privileges.php,v 1.34.2.2 2005/08/10 18:34:06 xzilla Exp $ */ // Include application functions @@ -168,8 +168,7 @@ // Get the privileges on the object, given its type $privileges = $data->getPrivileges($object, $_REQUEST['subject']); - - if (sizeof($privileges) > 0) { + if ($privileges > 0) { echo "\n"; echo ""; foreach ($data->privlist[$_REQUEST['subject']] as $v2) {
{$lang['strtype']}{$lang['struser']}/{$lang['strgroup']}