Browse Source

Sort room names

With a sizeable list of rooms managed by the bot, it can get
a little hard to find a specific room in the list if they
are added in random order. To make it a little easier to
visually parse the list, sort the room names.

Change-Id: Ia68c36346ea5fe542b6708a3f02ea911f348bc36
changes/69/499369/1
Sean McGinnis 4 years ago
parent
commit
77fe7f916a
1 changed files with 1 additions and 1 deletions
  1. +1
    -1
      ptgbot/db.py

+ 1
- 1
ptgbot/db.py View File

@ -49,7 +49,7 @@ class PTGDataBase():
return room in self.data['rooms']
def list_rooms(self):
return self.data['rooms']
return sorted(self.data['rooms'])
def add_rooms(self, rooms):
for room in rooms:


Loading…
Cancel
Save