summaryrefslogtreecommitdiffstats
path: root/git-interface
diff options
context:
space:
mode:
authorJohannes Löthberg <johannes@kyriasis.com>2015-06-23 14:18:14 +0200
committerLukas Fleischer <lfleischer@archlinux.org>2015-06-27 13:04:03 +0200
commite93f198edef454d179e6524d5162de0a014e5649 (patch)
tree47319ac7eb39b2ed6feb8e060b2125924e00889b /git-interface
parented0e2fd9751a04c759cd864aa838bc1f4e1ccd79 (diff)
downloadaur-e93f198edef454d179e6524d5162de0a014e5649.tar.gz
aur-e93f198edef454d179e6524d5162de0a014e5649.tar.xz
git-serve: Drop direct AccountType checking, use AUR_PRIVILEGED
Signed-off-by: Johannes Löthberg <johannes@kyriasis.com> Signed-off-by: Lukas Fleischer <lfleischer@archlinux.org>
Diffstat (limited to 'git-interface')
-rwxr-xr-xgit-interface/git-serve.py3
1 files changed, 1 insertions, 2 deletions
diff --git a/git-interface/git-serve.py b/git-interface/git-serve.py
index 9c9bddd5..8316cf7d 100755
--- a/git-interface/git-serve.py
+++ b/git-interface/git-serve.py
@@ -86,8 +86,7 @@ def check_permissions(pkgbase, user):
unix_socket=aur_db_socket, buffered=True)
cur = db.cursor()
- cur.execute("SELECT AccountTypeID FROM Users WHERE UserName = %s ", [user])
- if cur.fetchone()[0] > 1:
+ if os.environ.get('AUR_PRIVILEGED', '0') == '1':
return True
cur.execute("SELECT COUNT(*) FROM PackageBases " +