Commands addchar, addaccount, im and claim were long and complicated commands that performed similar operations, so the code was repeated all over them and if a bug was found in one, it had to be patched into all of them separately.
Their internal operations were merged into subfunctions, increasing their maintainability. Aditionally, they all use the DbChar class, instead of using queries directly.
addchar and addaccount were merged into a single command, asking the user if he wants to check other characters or not (similar to claim and im)
removechar and imnot were also cleaned up and had DbChar implemented.
addchar and removechar were moved to the Tracking cog.
settings command and subcommands where moved to the Admin cog, and the Settings cog was removed.
Implemented DbChar in the bind_database_character method and the serverlog cog.
Changes
addchar
,addaccount
,im
andclaim
were long and complicated commands that performed similar operations, so the code was repeated all over them and if a bug was found in one, it had to be patched into all of them separately. Their internal operations were merged into subfunctions, increasing their maintainability. Aditionally, they all use theDbChar
class, instead of using queries directly.addchar
andaddaccount
were merged into a single command, asking the user if he wants to check other characters or not (similar toclaim
andim
)removechar
andimnot
were also cleaned up and hadDbChar
implemented.addchar
andremovechar
were moved to theTracking
cog.settings
command and subcommands where moved to theAdmin
cog, and theSettings
cog was removed.DbChar
in thebind_database_character
method and the serverlog cog.