updated removal process for database elements
This commit is contained in:
parent
d17a76f4b8
commit
120931dc4c
@ -108,6 +108,12 @@ def deleteAccount():
|
||||
# TODO fix google delete account
|
||||
google.deleteAccount(current_user)
|
||||
|
||||
for cal in current_user.calendars:
|
||||
db.session.delete(cal)
|
||||
for dev in current_user.devices:
|
||||
db.session.delete(dev)
|
||||
|
||||
db.session.delete(current_user.google_token)
|
||||
db.session.delete(current_user)
|
||||
db.session.commit()
|
||||
logout_user()
|
||||
|
Loading…
Reference in New Issue
Block a user