summaryrefslogtreecommitdiffstats
path: root/web
diff options
context:
space:
mode:
authorCallan Barrett <wizzomafizzo@gmail.com>2008-06-04 17:02:30 +0200
committerLoui Chang <louipc.ist@gmail.com>2008-06-05 18:30:48 +0200
commita49ee80aa2e03843748e89185fd811d83cd34db9 (patch)
tree94e21c3a0844353f9b9e33868091d6a29a202ab7 /web
parent2f7d52dc8c72d7afd7b5d640aa913fe96b1708be (diff)
downloadaur-a49ee80aa2e03843748e89185fd811d83cd34db9.tar.gz
aur-a49ee80aa2e03843748e89185fd811d83cd34db9.tar.xz
Fix FS#8672
Patches can_submit_pkg(), this fixes the heaps of bugs people are having Signed-off-by: Callan Barrett <wizzomafizzo@gmail.com> Signed-off-by: Loui Chang <louipc.ist@gmail.com>
Diffstat (limited to 'web')
-rw-r--r--web/lib/aur.inc3
1 files changed, 2 insertions, 1 deletions
diff --git a/web/lib/aur.inc b/web/lib/aur.inc
index 168fa4b4..25c1d718 100644
--- a/web/lib/aur.inc
+++ b/web/lib/aur.inc
@@ -357,11 +357,12 @@ function html_footer($ver="") {
function can_submit_pkg($name="", $sid="") {
if (!$name || !$sid) {return 0;}
$dbh = db_connect();
- $q = "SELECT MaintainerUID ";
+ $q = "SELECT MaintainerUID, DummyPkg ";
$q.= "FROM Packages WHERE Name = '".mysql_real_escape_string($name)."'";
$result = db_query($q, $dbh);
if (mysql_num_rows($result) == 0) {return 1;}
$row = mysql_fetch_row($result);
+ if ($row[1] == "1") { return 1; }
$my_uid = uid_from_sid($sid);
if ($row[0] == $my_uid) {