mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 13:19:24 +01:00
Removed possible UnboundLocalError that would (a) crash the bot, and (b) never be reported.
This commit is contained in:
parent
14f008df26
commit
fa1115327f
@ -161,8 +161,11 @@ def recoverableException(type='detailed'):
|
|||||||
else:
|
else:
|
||||||
del lastTimes[0]
|
del lastTimes[0]
|
||||||
try:
|
try:
|
||||||
if type == 'detailed' and conf.detailedTracebacks:
|
if type == 'detailed':
|
||||||
text = cgitb.text((E, e, tb))
|
if conf.detailedTracebacks:
|
||||||
|
text = cgitb.text((E, e, tb))
|
||||||
|
else:
|
||||||
|
text = ''.join(traceback.format_exception(E, e, tb))
|
||||||
elif type == 'normal':
|
elif type == 'normal':
|
||||||
text = ''.join(traceback.format_exception(E, e, tb))
|
text = ''.join(traceback.format_exception(E, e, tb))
|
||||||
elif type == 'terse':
|
elif type == 'terse':
|
||||||
|
Loading…
Reference in New Issue
Block a user