app_manager 1.2.6 → 1.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3,30 +3,28 @@ require "app_manager/client/banners"
3
3
  require "app_manager/client/plans"
4
4
 
5
5
  module AppManager
6
- class Client
7
- include HTTParty
8
- include AppManager::Client::Connection
9
- include AppManager::Client::Banners
10
- include AppManager::Client::Plans
11
-
12
- # debug_output $stderr if Rails.env.development?
13
- # base_uri "https://app-manager.hulkapps.com/api"
14
- format :json
15
-
16
-
17
- def initialize(access_token = nil,json_req=false)
18
- access_token ||= ENV["APP_MANAGER_ACCESS_TOKEN"]
19
- hostport = ENV['APP_MANAGER_API_URL'] || 'https://app-manager.hulkapps.com'
20
- self.class.base_uri "#{hostport}/api"
21
- header = { 'token' => "#{access_token}"}
22
- header.merge!('Content-Type' => 'application/json') if json_req
23
- self.class.default_options.merge!(headers: header)
24
- end
25
-
26
- def is_json
27
-
28
- end
6
+ class Client
7
+ include HTTParty
8
+ include AppManager::Client::Connection
9
+ include AppManager::Client::Banners
10
+ include AppManager::Client::Plans
11
+
12
+ format :json
13
+
14
+
15
+ def initialize(access_token = nil, json_req = false)
16
+ access_token ||= ENV["APP_MANAGER_ACCESS_TOKEN"]
17
+ hostport = ENV['APP_MANAGER_API_URL'] || 'https://app-manager.hulkapps.com'
18
+ self.class.base_uri "#{hostport}/api"
19
+ header = {'token' => "#{access_token}"}
20
+ header.merge!('Content-Type' => 'application/json') if json_req
21
+ self.class.default_options.merge!(headers: header)
22
+ end
23
+
24
+ def is_json
29
25
 
30
26
  end
31
27
 
28
+ end
29
+
32
30
  end