Browse Source

Move this

master
Dylan Baker 4 years ago
parent
commit
3c91d89a3c
1 changed files with 4 additions and 4 deletions
  1. 4
    4
      lib/slack_mattermost_emoji/slack_client.rb

+ 4
- 4
lib/slack_mattermost_emoji/slack_client.rb View File

@@ -12,15 +12,15 @@ module SlackMattermostEmoji
12 12
       @log = log
13 13
       @authenticated = false
14 14
 
15
+      if [@username, @password, @domain].any? { |el| el.nil? || el.empty? }
16
+        raise 'Slack username, password, and domain are all required'
17
+      end
18
+
15 19
       Dir.mkdir(@download_path) unless Dir.exist?(@download_path)
16 20
 
17 21
       options = Selenium::WebDriver::Chrome::Options.new
18 22
       options.headless! unless headless == false
19 23
       @driver = Selenium::WebDriver.for :chrome, options: options
20
-
21
-      if [@username, @password, @domain].any? { |el| el.nil? || el.empty? }
22
-        raise 'Slack username, password, and domain are all required'
23
-      end
24 24
     end
25 25
 
26 26
     def authenticate

Loading…
Cancel
Save