mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
Store account type in local var when possible
No need to call this function way too often, especially when on the package list page where it could be called up to once per row. Signed-off-by: Dan McGee <dan@archlinux.org> Signed-off-by: Loui Chang <louipc.ist@gmail.com>
This commit is contained in:
parent
bf4fe7f47c
commit
8f97330100
3 changed files with 11 additions and 10 deletions
|
@ -49,8 +49,9 @@ if (isset($_COOKIE["AURSID"])) {
|
|||
<li><a href="pkgsubmit.php"><?php print __("Submit"); ?></a></li>
|
||||
<li><a href="packages.php?SeB=m&K=<?php print username_from_sid($_COOKIE["AURSID"]); ?>"><?php print __("My Packages"); ?></a></li>
|
||||
<?php
|
||||
if (account_from_sid($_COOKIE["AURSID"]) == "Trusted User"
|
||||
|| account_from_sid($_COOKIE["AURSID"]) == "Developer") {
|
||||
$SID = $_COOKIE['AURSID'];
|
||||
$atype = account_from_sid($SID);
|
||||
if ($atype == "Trusted User" || $atype == "Developer") {
|
||||
?>
|
||||
<li><a href="tu.php"><?php print __("Trusted User"); ?></a></li>
|
||||
<?php
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue