mirror of
https://github.com/Lost-MSth/Arcaea-server.git
synced 2026-02-10 09:47:26 +08:00
[Enhance] Self account delete
- Add support for users destroy their own accounts
This commit is contained in:
@@ -261,12 +261,3 @@ def ban_one_user(c, user_id):
|
||||
{'a': user_id})
|
||||
c.execute('''delete from login where user_id=:a''', {'a': user_id})
|
||||
return
|
||||
|
||||
|
||||
def clear_user_score(c, user_id):
|
||||
# 清除用户所有成绩,包括best_score和recent30,以及recent数据,但不包括云端存档
|
||||
c.execute('''update user set rating_ptt=0, song_id='', difficulty=0, score=0, shiny_perfect_count=0, perfect_count=0, near_count=0, miss_count=0, health=0, time_played=0, rating=0, world_rank_score=0 where user_id=:a''',
|
||||
{'a': user_id})
|
||||
c.execute('''delete from best_score where user_id=:a''', {'a': user_id})
|
||||
c.execute('''delete from recent30 where user_id=:a''', {'a': user_id})
|
||||
return
|
||||
|
||||
Reference in New Issue
Block a user