Added gem_dependency_check

Dominik Sander 10 ans auparavant
Parent
Commettre
4873b0b06e
1 fichiers modifiés avec 4 ajouts et 0 suppressions
  1. 4 0
      app/models/agents/wunderlist_agent.rb

+ 4 - 0
app/models/agents/wunderlist_agent.rb

@@ -6,7 +6,11 @@ module Agents
6 6
 
7 7
     cannot_be_scheduled!
8 8
 
9
+    gem_dependency_check { Devise.omniauth_providers.include?(:wunderlist) }
10
+
9 11
     description <<-MD
12
+      #{'## Include the `omniauth-wunderlist` gem in your `Gemfile` and set `WUNDERLIST_OAUTH_KEY` and `WUNDERLIST_OAUTH_SECRET` in your environment to use this Agent' if dependencies_missing?}
13
+
10 14
       The WunderlistAgent creates new new tasks based on the incoming event.
11 15
 
12 16
       To be able to use this Agent you need to authenticate with Wunderlist in the [Services](/services) section first.