diff options
author | Dmitry Kim <dmitry point kim at gmail point com> | 2007-08-30 18:16:19 +0000 |
---|---|---|
committer | Dmitry Kim <dmitry point kim at gmail point com> | 2007-08-30 18:16:19 +0000 |
commit | 96f214843f3e667b0a34955b0632ca834bb9ecfe (patch) | |
tree | 069e26e3b087bc57da9c15e0e4e300f5f6222af3 /lib/rbot | |
parent | d4ebd66d357b9200edabd1f6d4fa1b3c72d048e6 (diff) |
* (ircbot) block autosave timer during rescan/restart
Diffstat (limited to 'lib/rbot')
-rw-r--r-- | lib/rbot/ircbot.rb | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/rbot/ircbot.rb b/lib/rbot/ircbot.rb index 889daed0..507fa907 100644 --- a/lib/rbot/ircbot.rb +++ b/lib/rbot/ircbot.rb @@ -1048,6 +1048,7 @@ class Bot debug "\tsaving ..." save debug "\tcleaning up ..." + @timer.block(@save_timer) if @save_timer @save_mutex.synchronize do @plugins.cleanup end @@ -1100,10 +1101,12 @@ class Bot # call the rescan method for all of the botmodules def rescan + @timer.block(@save_timer) if @save_timer @save_mutex.synchronize do @lang.rescan @plugins.rescan end + @timer.unblock(@save_timer) if config['core.save_every'] > 0 end # channel:: channel to join |