Python 3 Start
This commit is contained in:
parent
9f029c8ceb
commit
141fe8d80c
67 changed files with 264 additions and 274 deletions
|
@ -1,6 +1,6 @@
|
|||
import os
|
||||
import sqlite3
|
||||
import thread
|
||||
import _thread
|
||||
|
||||
threaddbs = {}
|
||||
|
||||
|
@ -11,7 +11,7 @@ def get_db_connection(conn, name=''):
|
|||
if not name:
|
||||
name = '{}.db'.format(conn.name)
|
||||
|
||||
threadid = thread.get_ident()
|
||||
threadid = _thread.get_ident()
|
||||
if name in threaddbs and threadid in threaddbs[name]:
|
||||
return threaddbs[name][threadid]
|
||||
filename = os.path.join(bot.data_dir, name)
|
||||
|
|
Reference in a new issue