nonchris / discord-fury

Customizable discord bot for voice channels on demand and breakout rooms
GNU General Public License v3.0
12 stars 7 forks source link

Fix databse and some minor issues during chanenl creation #29

Closed nonchris closed 3 years ago

nonchris commented 3 years ago

The data-base had some rather serious issues. There were two terms for public and private channels public-channel / pub and private-channel / priv those both existed in the database but there were parts in the code where only one of both entry names was requested from the db. This may have caused a lot of trouble.

The code now supports both names to ensure that old db entries are still supported or for the case that I missed something. But all new entries will use the short terms.

I also added a lot of minor fixes in on_voice_update.py which handle cases where a user leaves the channel before the creation process is finished, which caused the database to not register those channels and so they weren't deleted by the bot.

This is now fixed by some exception handling that catches most edge cases and handles them properly.