mirror of
https://github.com/Fishwaldo/huginn.git
synced 2025-03-15 19:31:26 +00:00
Adds validation for Tumblr class definition
This commit is contained in:
parent
05563022c7
commit
5489f80cb6
1 changed files with 6 additions and 0 deletions
|
@ -7,6 +7,8 @@ module Agents
|
|||
cannot_be_scheduled!
|
||||
|
||||
description <<-MD
|
||||
#{'## Include `tumblr_client` and `omniauth-tumblr` in your Gemfile to use this Agent!' if dependencies_missing?}
|
||||
|
||||
The TumblrPublishAgent publishes Tumblr posts from the events it receives.
|
||||
|
||||
To be able to use this Agent you need to authenticate with Tumblr in the [Services](/services) section first.
|
||||
|
@ -55,6 +57,10 @@ module Agents
|
|||
Set `expected_update_period_in_days` to the maximum amount of time that you'd expect to pass between Events being created by this Agent.
|
||||
MD
|
||||
|
||||
def gem_dependency_check
|
||||
defined?(Tumblr)
|
||||
end
|
||||
|
||||
def validate_options
|
||||
errors.add(:base, "expected_update_period_in_days is required") unless options['expected_update_period_in_days'].present?
|
||||
end
|
||||
|
|
Loading…
Add table
Reference in a new issue