Ajout du destructeur de la classe Database
This commit is contained in:
parent
2741e3ae5e
commit
792b3fca33
@ -39,6 +39,9 @@ class Database:
|
|||||||
result = cursor.fetchall()
|
result = cursor.fetchall()
|
||||||
cursor.close()
|
cursor.close()
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
def __del__(self):
|
||||||
|
self.db.close()
|
||||||
|
|
||||||
class User:
|
class User:
|
||||||
def __init__(self, user_id, username, nom, prenom, creation_date):
|
def __init__(self, user_id, username, nom, prenom, creation_date):
|
||||||
|
Loading…
Reference in New Issue
Block a user