Add default delay range, configure check
This commit is contained in:
parent
730f833d6d
commit
64c1aa411c
1 changed files with 5 additions and 0 deletions
|
@ -180,12 +180,17 @@ module Ebooks
|
|||
@seen_tweets ||= {}
|
||||
|
||||
@username = username
|
||||
@delay_range ||= 1..6
|
||||
configure
|
||||
|
||||
b.call(self) unless b.nil?
|
||||
Bot.all << self
|
||||
end
|
||||
|
||||
def configure
|
||||
raise ConfigurationError, "Please override the 'configure' method for subclasses of Ebooks::Bot."
|
||||
end
|
||||
|
||||
# Find or create the conversation context for this tweet
|
||||
# @param tweet [Twitter::Tweet]
|
||||
# @return [Ebooks::Conversation]
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue