Browse Source

Clean up stale data presence on a #newday command

Data presence was not reset on a new day cleanup, while it
is almost certainly stale at this point. Hopefully.

Change-Id: Ifc4cdedf6c365f92e5ff001d1485c8fee21b396f
changes/78/670578/1
Thierry Carrez 6 months ago
parent
commit
18dbbc69f4
2 changed files with 3 additions and 1 deletions
  1. +2
    -1
      README.rst
  2. +1
    -0
      ptgbot/db.py

+ 2
- 1
README.rst View File

@@ -182,7 +182,8 @@ You have to be a channel operator (+o) to use admin commands.
Removes active entries for specified track(s)

~newday
Removes now/next/location entries, to be run at the start of a new day
Removes existing now/next/location/presence entries. This command is
meant to be run at the start of a new day

~motd LEVEL MESSAGE
Adds a message of the day on top of the rendered page. Level must be one of

+ 1
- 0
ptgbot/db.py View File

@@ -191,6 +191,7 @@ class PTGDataBase():
self.data['now'] = OrderedDict()
self.data['next'] = OrderedDict()
self.data['location'] = OrderedDict()
self.data['last_check_in'] = OrderedDict()
self.clean_motd()

def empty(self):

Loading…
Cancel
Save