rail-locator-api 0.1.10 → 0.1.11
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:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: f4116acecc37e9c45d4555f0edfa0a976a7d9b371d68cfa251d7cc9070e1972e
|
|
4
|
+
data.tar.gz: e82ea4484f36be5cec4666543a9bd83b82f6253a842be94fe03fd1adabeed9be
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 74d3391f55d3815fe5170a1e87521b1c133622c4d5ad9c8b75595e1f5dc92a1c9c1014f5db0e5866dbcabce0f8e7399d00d5b01f5127d84888de27c48c160d3b
|
|
7
|
+
data.tar.gz: 7006b7960aa5bb4ea79108d30b548039352c376eb534c4832bfbc309d5966c9b366bd81e0726e0b4f87a2e51311bcffccd430420f9f11ad5f32c9631cc51e7da
|
|
@@ -143,7 +143,7 @@ module RailLocatorApi
|
|
|
143
143
|
|
|
144
144
|
def rest_client(suffix=nil)
|
|
145
145
|
client = Faraday.new("#{self.api_url}#{suffix.present? ? "/#{suffix}": ""}", proxy: self.proxy,
|
|
146
|
-
ssl:
|
|
146
|
+
ssl: self.ssl_options) do |faraday|
|
|
147
147
|
faraday.request :gzip
|
|
148
148
|
faraday.response :raise_error
|
|
149
149
|
faraday.adapter adapter
|
data/lib/rail-locator-api.rb
CHANGED
|
@@ -16,7 +16,7 @@ module RailLocatorApi
|
|
|
16
16
|
payload = "grant_type=#{RailLocatorApi.keycloak_grant_type}&client_id=#{RailLocatorApi.keycloak_client_id}&client_secret=#{RailLocatorApi.keycloak_client_secret}&code=#{RailLocatorApi::Request.api_key}&redirect_uri=#{RailLocatorApi.keycloak_redirect_uri}"
|
|
17
17
|
end
|
|
18
18
|
connection = Faraday.new(RailLocatorApi.keycloak_token_url, proxy: nil,
|
|
19
|
-
ssl: { version: "TLSv1_2" }) do |faraday|
|
|
19
|
+
ssl: RailLocatorApi::Request.ssl_options || { version: "TLSv1_2" }) do |faraday|
|
|
20
20
|
faraday.adapter Faraday.default_adapter
|
|
21
21
|
faraday.response :logger, ::Logger.new(STDOUT), bodies: true
|
|
22
22
|
end
|
|
@@ -31,7 +31,7 @@ module RailLocatorApi
|
|
|
31
31
|
def refresh_access_token
|
|
32
32
|
payload = "grant_type=refresh_token&client_id=#{RailLocatorApi.keycloak_client_id}&client_secret=#{RailLocatorApi.keycloak_client_secret}&refresh_token=#{RailLocatorApi::Request.refresh_token}&redirect_uri=#{RailLocatorApi.keycloak_redirect_uri}"
|
|
33
33
|
connection = Faraday.new(RailLocatorApi.keycloak_token_url, proxy: nil,
|
|
34
|
-
ssl: { version: "TLSv1_2" }) do |faraday|
|
|
34
|
+
ssl: RailLocatorApi::Request.ssl_options || { version: "TLSv1_2" }) do |faraday|
|
|
35
35
|
faraday.adapter Faraday.default_adapter
|
|
36
36
|
faraday.response :logger, ::Logger.new(STDOUT), bodies: true
|
|
37
37
|
end
|