diff options
author | canyonknight <canyonknight@gmail.com> | 2012-08-10 03:15:50 +0200 |
---|---|---|
committer | Lukas Fleischer <archlinux@cryptocrack.de> | 2012-08-23 22:47:50 +0200 |
commit | e8cd6abc6e8921223a7a290088153bffc364e9d5 (patch) | |
tree | 9883f62565332efc4a3c2a999b183ac27912ca55 /web/template/pkg_details.php | |
parent | 44d8588b6304c12ef8ae8b3151a697a73dce526d (diff) | |
download | aur-e8cd6abc6e8921223a7a290088153bffc364e9d5.tar.gz aur-e8cd6abc6e8921223a7a290088153bffc364e9d5.tar.xz |
Allow only Trusted Users, Developers, and Maintainers to unflag packages
Currently everyone is allowed to unflag a package as out of date. This should
be limited to only the appropriate people for a specific package.
Fixes FS#27263
Signed-off-by: canyonknight <canyonknight@gmail.com>
Signed-off-by: Lukas Fleischer <archlinux@cryptocrack.de>
Diffstat (limited to 'web/template/pkg_details.php')
-rw-r--r-- | web/template/pkg_details.php | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/web/template/pkg_details.php b/web/template/pkg_details.php index da173ec1..7176e106 100644 --- a/web/template/pkg_details.php +++ b/web/template/pkg_details.php @@ -40,7 +40,8 @@ $sources = package_sources($row["ID"]); <?php if ($USE_VIRTUAL_URLS && $uid): ?> <?php if ($row["OutOfDateTS"] === NULL): ?> <li><a href="<?php echo get_pkg_uri($row['Name']) . 'flag/'; ?>"><?php echo __('Flag package out-of-date'); ?></a></li> - <?php else: ?> + <?php elseif (($row["OutOfDateTS"] !== NULL) && + ($uid == $row["MaintainerUID"] || $atype == "Trusted User" || $atype == "Developer")): ?> <li><a href="<?php echo get_pkg_uri($row['Name']) . 'unflag/'; ?>"><?php echo __('Unflag package'); ?></a></li> <?php endif; ?> <?php if (user_voted($uid, $row['ID'])): ?> |