From 8dfebf69702193527ecffc336f465d7b8c6f6fb4 Mon Sep 17 00:00:00 2001 From: Juhani Haverinen Date: Fri, 5 Feb 2016 17:26:43 +0200 Subject: [PATCH] Allow untrusting deleted accounts --- botcmd.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/botcmd.py b/botcmd.py index 1e7fa34..32336ce 100644 --- a/botcmd.py +++ b/botcmd.py @@ -516,6 +516,10 @@ def parse((line, irc)): untrustnick = parsecmd(cmdline, 'nick') if isauthorized(irc, chan, nick): account = getaccount(irc, untrustnick) + # If account can't be found (e.g. it has been deleted, use the parameter as-is + if not account: + if istrusted(chan, untrustnick): + account = untrustnick if account: godslock.acquire() if chan not in gods or account not in gods[chan]: