Commit 7a53ded5 authored by Lukas Fleischer's avatar Lukas Fleischer
Browse files

git-update: Fix some issues reported by pyflakes



Signed-off-by: Lukas Fleischer's avatarLukas Fleischer <lfleischer@archlinux.org>
parent 12ab89b7
......@@ -167,11 +167,13 @@ def save_metadata(metadata, db, cur, user):
"PackageBaseID = %s AND UserID = %s",
[pkgbase_id, user_id])
if cur.fetchone()[0] == 0:
cur.execute("INSERT INTO PackageNotifications (PackageBaseID, UserID) " +
"VALUES (%s, %s)", [pkgbase_id, user_id])
cur.execute("INSERT INTO PackageNotifications " +
"(PackageBaseID, UserID) VALUES (%s, %s)",
[pkgbase_id, user_id])
db.commit()
def update_notify(db, cur, user, pkgbase_id):
# Obtain the user ID of the new maintainer.
cur.execute("SELECT ID FROM Users WHERE Username = %s", [user])
......@@ -180,6 +182,7 @@ def update_notify(db, cur, user, pkgbase_id):
# Execute the notification script.
subprocess.Popen((notify_cmd, 'update', str(user_id), str(pkgbase_id)))
def die(msg):
sys.stderr.write("error: {:s}\n".format(msg))
exit(1)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment