Diverse Bugfixes

This commit is contained in:
Enno Rehling 2001-11-07 00:45:45 +00:00
parent 2a76bb8c2d
commit 24f3cbd6ae
3 changed files with 7 additions and 3 deletions

View file

@ -38,6 +38,7 @@ for line in infile.readlines():
if match!=None:
To = match.group(1)
Reason = match.group(2)
print "ERROR: "+To+": "+Reason
Msg = ("From: "+From+"\nTo: "+To+"\nSubject: Vinyambar Anmeldung fehlgeschlagen.\n\n"
+"Deine Anmeldung konnte aus folgendem Grund nicht akzeptiert werden:\n "+Reason+"\n")
try:

View file

@ -151,13 +151,16 @@ else:
cursor.execute("INSERT INTO users (firstname, lastname, email, address, city, phone, country, password) "+
"VALUES ('"+firstname+"', '"+lastname+"', '"+email+"', '"+address+"', '"+city+"', '"+phone+"', "+country+", '"+genpasswd()+"')")
cursor.execute("SELECT LAST_INSERT_ID() from dual")
lastid=str(int(cursor.fetchone()[0]))
if (oldrace!=None):
cursor.execute("INSERT INTO subscriptions (user, race, game) "+
"VALUES (LAST_INSERT_ID(), '"+oldrace+"', 1)")
"VALUES ("+lastid+", '"+oldrace+"', 1)")
if (newrace!=None):
cursor.execute("INSERT INTO subscriptions (user, race, game) "+
"VALUES (LAST_INSERT_ID(), '"+newrace+"', 1)")
"VALUES ("+lastid+", '"+newrace+"', 2)")
errors.close()
unlock(sys.argv[1]+".err")