authreqs: add get_irc_bot(), utter hackjob but works for now

This commit is contained in:
William Pitcock 2018-08-17 17:42:32 -05:00
parent 0742ff20b0
commit 489a01fc9e
1 changed files with 7 additions and 0 deletions

View File

@ -43,6 +43,7 @@ def new_auth_req(irc_nickname, irc_account):
return authid return authid
# XXX - utter hackjob
def set_irc_bot(bot): def set_irc_bot(bot):
global IRC_BOT global IRC_BOT
@ -50,6 +51,12 @@ def set_irc_bot(bot):
logging.debug("SET IRC BOT TO: %r", bot) logging.debug("SET IRC BOT TO: %r", bot)
def get_irc_bot():
global IRC_BOT
return IRC_BOT
def check_auth(account): def check_auth(account):
return account in DATABASE["auths"] return account in DATABASE["auths"]