Make sure we always return true from Main#on_timer.
authorTilman Sauerbeck <tilman@code-monkey.de>
Mon, 27 Aug 2007 17:57:50 +0000 (19:57 +0200)
committerTilman Sauerbeck <tilman@code-monkey.de>
Mon, 27 Aug 2007 17:57:50 +0000 (19:57 +0200)
Before we returned nil if we still had a connection to the server.
This didn't cause the timer to stop only because of an ruby-ecore bug.

bin/embrace

index 77e57a93100d17d7a788a7db3599c3db5d910fe2..dc4fafc4904c2eff5a7d374190193f7d80fd0622 100755 (executable)
@@ -394,9 +394,7 @@ module Embrace
 
                private
                def on_timer
-                       return unless @server.nil?
-
-                       @server = IMAP::Session.new(@config)
+                       @server ||= IMAP::Session.new(@config)
 
                        true
                end