- cursor.execute("insert into account(token, cipher) values(%s, %s)", (key, raw))
- conn.commit()
+ if DBTYPE != 'sqlite':
+ cursor.execute("insert into account(token, cipher) values(%s, %s)", (key, raw))
+ conn.commit()
+ else:
+ cursor.execute('begin')
+ cursor.execute("insert into account(token, cipher) values(?, ?)", (key, raw))
+ cursor.execute('commit')