diff options
Diffstat (limited to 'web')
-rw-r--r-- | web/html/packages.php | 5 | ||||
-rw-r--r-- | web/lib/pkgfuncs.inc | 4 |
2 files changed, 7 insertions, 2 deletions
diff --git a/web/html/packages.php b/web/html/packages.php index 95b59798..85ab6b75 100644 --- a/web/html/packages.php +++ b/web/html/packages.php @@ -171,7 +171,10 @@ if (isset($_REQUEST["do_Flag"])) { $q = "UPDATE Packages "; $q.= "SET ".$field." = 0 "; $q.= "WHERE ID IN (" . $disown . ") "; - $q.= "AND ".$field." = ".uid_from_sid($_COOKIE["AURSID"]); + # If a user is a TU or dev they can disown any package + if ($atype == "User") { + $q.= "AND ".$field." = ".uid_from_sid($_COOKIE["AURSID"]); + } db_query($q, $dbh); } diff --git a/web/lib/pkgfuncs.inc b/web/lib/pkgfuncs.inc index ad9630e9..eaeeca8b 100644 --- a/web/lib/pkgfuncs.inc +++ b/web/lib/pkgfuncs.inc @@ -492,7 +492,9 @@ function package_details($id=0, $SID="") { echo " value='".__("Adopt Packages")."'>\n"; } - if ($row["MaintainerUID"] == uid_from_sid($SID)) { + if ($row["MaintainerUID"] == uid_from_sid($SID) || + account_from_sid($SID) == "Trusted User" || + account_from_sid($SID) == "Developer") { echo "<input type='submit' class='button' name='do_Disown'"; echo " value='".__("Disown Packages")."'>\n"; } |