Add files via upload

This commit is contained in:
Bluzume 2019-09-16 07:20:15 +12:00 committed by GitHub
parent 6787afb350
commit c72d2196d5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -41,7 +41,7 @@ def TryAdd():
cur = c.execute('SELECT COUNT(1) from itemList WHERE Name=? and ItemId=?',(username,ItemId))
rows = cur.fetchone()
count = rows[0]
if count == 0:
if count != 0:
c.execute('UPDATE itemList SET Quantity=Quantity+? WHERE Name=? and ItemId=?',(Quantity,username,ItemId))
return 0
else: