rail-locator-api 0.1.32 → 0.1.33

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.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 010b8eebc008a19fb48adfe1ec30c3319b0617ae0d16a0dfa97e9c39260d0869
4
- data.tar.gz: 47f584ea0d3f67d553d82975bd0f84b4768ae78cc2ed45629a7a6964407463ea
3
+ metadata.gz: f44c8ebe2596d7f03175522989e26bd54d1115e289330cfae7ec4b667439defb
4
+ data.tar.gz: 7ee33751cf6e02ad85ffd02e27c5026a90ce0e510f459476a26f62714377acbf
5
5
  SHA512:
6
- metadata.gz: 68770511d3498591f8c630f5149da2cf97f27b97e2ab32bbd80e0c2f06e9fe26b31e96368b7c57efd7d3dbdb6dd7d1d59820aab29a9054aa0f7923374ad48c10
7
- data.tar.gz: 5b7ef346980f0ebc01b7df58cc62c00c590744828595683f8f2ead25a69c321413f4a7a5fbbac3811468cb58e33af2a486b93cce5df397540ab42b519a00ff1c
6
+ metadata.gz: d03c4b4eb7811f69c619148319638554a8a16c2df41ac4544bc9169712850ebe3ab120933d202297512cd994e0b8f53561263974a1e18b6f1a5b0bc20493dcfb
7
+ data.tar.gz: 0bea1677fe6c007835ad62e10116930350adba98d4e0956d9926e7bd09089b54190c546a5ea187d2a15955330971000b6198068dbc4055197f7a5c41aaf6b21c
@@ -17,5 +17,6 @@ RailLocatorApi.setup do |config|
17
17
  config::Request.open_timeout = 60
18
18
  config::Request.symbolize_keys = true
19
19
  config::Request.debug = false
20
+ config::Request.debug_options = { headers: true, bodies: false, errors: false, log_level: :info } # https://lostisland.github.io/faraday/middleware/logger
20
21
  end
21
22
  end
@@ -177,7 +177,7 @@ module RailLocatorApi
177
177
  faraday.response :raise_error
178
178
  faraday.adapter adapter
179
179
  if @request_builder.debug
180
- faraday.response :logger, @request_builder.logger, bodies: true
180
+ faraday.response :logger, @request_builder.logger, @request_builder.debug_options
181
181
  end
182
182
  end
183
183
  client
@@ -11,7 +11,9 @@ module RailLocatorApi
11
11
 
12
12
  def initialize(access_token: nil, refresh_token: nil, api_user_id: nil, api_key: nil, api_user_email: nil, api_user_password: nil,
13
13
  api_endpoint: nil, api_auth_method: nil, timeout: nil, open_timeout: nil, proxy: nil, ssl_options: nil,
14
- faraday_adapter: nil, symbolize_keys: false, debug: false, without_ratelimit: false, is_allow_access_to_coordinates: false,
14
+ faraday_adapter: nil, symbolize_keys: false, debug: false,
15
+ debug_options: { headers: true, bodies: false, errors: false, log_level: :info },
16
+ without_ratelimit: false, is_allow_access_to_coordinates: false,
15
17
  logger: nil, test: false)
16
18
 
17
19
  @path_parts = []
@@ -42,6 +44,7 @@ module RailLocatorApi
42
44
  @faraday_adapter = faraday_adapter || self.class.faraday_adapter || Faraday.default_adapter
43
45
  @symbolize_keys = symbolize_keys || self.class.symbolize_keys || false
44
46
  @debug = debug || self.class.debug || false
47
+ @debug_options = debug_options || self.class.debug_options || { headers: true, bodies: false, errors: false, log_level: :info }
45
48
  @without_ratelimit = without_ratelimit || self.class.without_ratelimit
46
49
  @is_allow_access_to_coordinates = is_allow_access_to_coordinates || self.class.is_allow_access_to_coordinates
47
50
  @test = test || self.class.test || false
@@ -1,3 +1,3 @@
1
1
  module RailLocatorApi
2
- VERSION = "0.1.32"
2
+ VERSION = "0.1.33"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rail-locator-api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.32
4
+ version: 0.1.33
5
5
  platform: ruby
6
6
  authors:
7
7
  - Pavel Osetrov