garsh 0.1.0 → 0.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/garsh.rb +2 -1
- data/lib/garsh/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 724fc9c4150c48729db344d80108f8b95c66738b
|
4
|
+
data.tar.gz: 772d586d2a66866eb320ee52c12cdd264211e24c
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: bb91d315fdca204a72014636a73f1e58479bc8ee7f0ef431b1a95ddc5e4a211a200fcb5dd34244a0277a57eb0ade5d28c2a186af59be77c7a58d3e6b8bbab2f4
|
7
|
+
data.tar.gz: 4c375aed8fdd364f81000e10e8babe4fd961273b92146f6285e2a89c4685f07425f7fecac0a97226cd9914bba4e76b5d35d45c3d39211b17c1b9f0a1d3d19fd3
|
data/lib/garsh.rb
CHANGED
@@ -14,6 +14,7 @@ class Garsh
|
|
14
14
|
|
15
15
|
def initialize(code)
|
16
16
|
@code = code
|
17
|
+
@adapter = defined?(Typhoeus) ? :typhoeus : Faraday.default_adapter
|
17
18
|
end
|
18
19
|
|
19
20
|
def create_event(action:, category: "", client_id: "555")
|
@@ -23,7 +24,7 @@ class Garsh
|
|
23
24
|
|
24
25
|
def send_payload(endpoint, params)
|
25
26
|
@http_client ||= Faraday.new(url: GA_ENDPOINT) { |cli|
|
26
|
-
cli.adapter
|
27
|
+
cli.adapter @adapter
|
27
28
|
cli.response :logger
|
28
29
|
}
|
29
30
|
@http_client.get(endpoint, params)
|
data/lib/garsh/version.rb
CHANGED