From 4be7e90e6691c69e23f8377dcdd7b1bcec2dcd48 Mon Sep 17 00:00:00 2001 From: Chris Morgan Date: Sat, 30 Jul 2005 16:35:03 +0000 Subject: [PATCH] user->isMaintainer() should return true if the user is a super maintainer of the application --- include/user.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/include/user.php b/include/user.php index 08ef459..c67547a 100644 --- a/include/user.php +++ b/include/user.php @@ -201,6 +201,13 @@ class User { function isMaintainer($iVersionId=null) { if(!$this->isLoggedIn()) return false; + + /* if we are a super maintainer, we are a maintainer of this version as well */ + $oVersion = new Version($iVersionId); + if($this->isSuperMaintainer($oVersion->iAppId)) + return true; + + /* otherwise check if we maintain this specific version */ if($iVersionId) { $sQuery = "SELECT * FROM appMaintainers WHERE userid = '".$this->iUserId."' AND versionId = '$iVersionId'";