mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-02-18 22:51:01 +01:00
Just create schedule.schedule/drivers.Twisted.poller without any guard
These module-level variables had historically been created such that reloading the module wouldn't redefine the variable. However, none of our code reloads the modules and the guard to prevent redefining the variable was broken so it would've been redefined anyway. Signed-off-by: James McCoy <jamessan@users.sourceforge.net>
This commit is contained in:
parent
14609b3bb2
commit
97e71bd2cd
@ -155,9 +155,6 @@ class SupyReconnectingFactory(ReconnectingClientFactory, drivers.ServersMixin):
|
|||||||
return protocol
|
return protocol
|
||||||
|
|
||||||
Driver = SupyReconnectingFactory
|
Driver = SupyReconnectingFactory
|
||||||
|
poller = TwistedRunnerDriver()
|
||||||
|
|
||||||
try:
|
|
||||||
ignore(poller)
|
|
||||||
except NameError:
|
|
||||||
poller = TwistedRunnerDriver()
|
|
||||||
# vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79:
|
# vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79:
|
||||||
|
@ -131,11 +131,8 @@ 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:
|
|
||||||
ignore(schedule)
|
|
||||||
except NameError:
|
|
||||||
schedule = Schedule()
|
|
||||||
|
|
||||||
|
schedule = Schedule()
|
||||||
addEvent = schedule.addEvent
|
addEvent = schedule.addEvent
|
||||||
removeEvent = schedule.removeEvent
|
removeEvent = schedule.removeEvent
|
||||||
rescheduleEvent = schedule.rescheduleEvent
|
rescheduleEvent = schedule.rescheduleEvent
|
||||||
|
Loading…
x
Reference in New Issue
Block a user