mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-23 11:09:23 +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
|
||||
|
||||
Driver = SupyReconnectingFactory
|
||||
poller = TwistedRunnerDriver()
|
||||
|
||||
try:
|
||||
ignore(poller)
|
||||
except NameError:
|
||||
poller = TwistedRunnerDriver()
|
||||
# vim:set shiftwidth=4 softtabstop=4 expandtab textwidth=79:
|
||||
|
@ -131,11 +131,8 @@ class Schedule(drivers.IrcDriver):
|
||||
except Exception, e:
|
||||
log.exception('Uncaught exception in scheduled function:')
|
||||
|
||||
try:
|
||||
ignore(schedule)
|
||||
except NameError:
|
||||
schedule = Schedule()
|
||||
|
||||
schedule = Schedule()
|
||||
addEvent = schedule.addEvent
|
||||
removeEvent = schedule.removeEvent
|
||||
rescheduleEvent = schedule.rescheduleEvent
|
||||
|
Loading…
Reference in New Issue
Block a user