[Tell] Actually write changes to disk
This commit is contained in:
parent
4832424cac
commit
5046faedd8
3
tell.py
3
tell.py
@ -32,6 +32,7 @@ def tell(phenny, input):
|
|||||||
c = db.cursor()
|
c = db.cursor()
|
||||||
c.execute("INSERT INTO tell VALUES (?,?,?)", d)
|
c.execute("INSERT INTO tell VALUES (?,?,?)", d)
|
||||||
c.close()
|
c.close()
|
||||||
|
db.commit()
|
||||||
db.close()
|
db.close()
|
||||||
|
|
||||||
response = "I'll pass that on when %s is around" % target
|
response = "I'll pass that on when %s is around" % target
|
||||||
@ -52,6 +53,7 @@ def checktell(phenny, input):
|
|||||||
c = db.cursor()
|
c = db.cursor()
|
||||||
c.execute("DELETE FROM tell WHERE nick = ? AND channel = ? AND msg = ?", e)
|
c.execute("DELETE FROM tell WHERE nick = ? AND channel = ? AND msg = ?", e)
|
||||||
c.close()
|
c.close()
|
||||||
|
db.commit()
|
||||||
db.close()
|
db.close()
|
||||||
return
|
return
|
||||||
|
|
||||||
@ -80,6 +82,7 @@ while True:
|
|||||||
break
|
break
|
||||||
tell_list.append(e)
|
tell_list.append(e)
|
||||||
c.close()
|
c.close()
|
||||||
|
db.commit()
|
||||||
db.close()
|
db.close()
|
||||||
|
|
||||||
if __name__ == '__main__':
|
if __name__ == '__main__':
|
||||||
|
Loading…
x
Reference in New Issue
Block a user