mirror of
https://github.com/jlu5/PyLink.git
synced 2024-12-25 04:02:45 +01:00
fantasy: break if IRC object isn't ready
This commit is contained in:
parent
cf363432f0
commit
b100f30cfe
@ -8,6 +8,11 @@ from log import log
|
||||
|
||||
def handle_fantasy(irc, source, command, args):
|
||||
"""Fantasy command handler."""
|
||||
|
||||
if not irc.connected.is_set():
|
||||
# Break if the IRC network isn't ready.
|
||||
return
|
||||
|
||||
try: # First, try to fetch the config-defined prefix.
|
||||
prefixes = [irc.botdata["prefix"]]
|
||||
except KeyError: # Config option is missing.
|
||||
|
Loading…
Reference in New Issue
Block a user