Ping joined players even if the bot was quit and restarted manually
This commit is contained in:
parent
4ab966fc06
commit
1db767cafa
@ -488,6 +488,15 @@ def forced_exit(cli, nick, chan, rest):
|
||||
except Exception:
|
||||
notify_error(cli, chan, errlog)
|
||||
|
||||
try:
|
||||
with sqlite3.connect("data.sqlite3", check_same_thread=False) as conn:
|
||||
c = conn.cursor()
|
||||
players = var.list_players()
|
||||
if players:
|
||||
c.execute("UPDATE pre_restart_state SET players = ?", (" ".join(players),))
|
||||
except Exception:
|
||||
notify_error(cli, chan, errlog)
|
||||
|
||||
try:
|
||||
reset()
|
||||
except Exception:
|
||||
|
Loading…
Reference in New Issue
Block a user