Check globals() instead of catching NameError.

This commit is contained in:
Valentin Lorentz 2012-05-02 20:58:36 +02:00
parent af460596d3
commit 446349357d
2 changed files with 4 additions and 4 deletions

View File

@ -131,9 +131,9 @@ class Schedule(drivers.IrcDriver):
except Exception, e: except Exception, e:
log.exception('Uncaught exception in scheduled function:') log.exception('Uncaught exception in scheduled function:')
try: if 'ignore' in globals():
ignore(schedule) globals()['ignore'](schedule)
except NameError: else:
schedule = Schedule() schedule = Schedule()
addEvent = schedule.addEvent addEvent = schedule.addEvent

View File

@ -1,3 +1,3 @@
"""stick the various versioning attributes in here, so we only have to change """stick the various versioning attributes in here, so we only have to change
them once.""" them once."""
version = '0.83.4.1+limnoria (2012-05-02T18:50:06+0000)' version = '0.83.4.1+limnoria (2012-05-02T18:58:36+0000)'