zooppa_api_v3 0.0.2 → 0.0.3
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 +4 -4
- data/lib/zooppa_api_v3.rb +1 -16
- data/zooppa_api_v3.gemspec +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA1:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 430a1b73bfa135925af4e18bae421799e7fd3000
|
|
4
|
+
data.tar.gz: a480120bb72242a58b30dde638554ce3672a3d49
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: 3f1571dcea231ded24b1e759c95a5f01f7787e01227f93a4e77d92c92f9dc1ae3e07b81ef3d9fbcc44c89b48d0af392884b80eab8d236ab66d4142ea042ae149
|
|
7
|
+
data.tar.gz: 999e44fc12e45a7561e2692366e9c9070885af90712fdcbc11fecf3c133a3532392e4b34bf9b2d34aca6187e34d47dd7c9e04e7da56ff72008f7c198386f4b35
|
data/lib/zooppa_api_v3.rb
CHANGED
|
@@ -162,24 +162,9 @@ class ZooppaApiV3
|
|
|
162
162
|
return pagination_params
|
|
163
163
|
end
|
|
164
164
|
|
|
165
|
-
def prepare_request(resource, **args)
|
|
166
|
-
@resource = resource
|
|
167
|
-
@method = args.fetch(:method) { :get }
|
|
168
|
-
@id = args.fetch(:id) { nil }
|
|
169
|
-
@params = args.fetch(:params) { {} }
|
|
170
|
-
@cookies = args.fetch(:cookies) { {} }
|
|
171
|
-
@authenticate = args.fetch(:authenticate) { false }
|
|
172
|
-
@url = build_url
|
|
173
|
-
|
|
174
|
-
if @authenticate
|
|
175
|
-
fail Exceptions::MissingAuthToken unless @cookies.key?(:auth_token)
|
|
176
|
-
add_auth_token
|
|
177
|
-
end
|
|
178
|
-
end
|
|
179
|
-
|
|
180
165
|
# Adds the auth_token to the params hash or url (depending on the HTTP verb)
|
|
181
166
|
def add_auth_token(token)
|
|
182
|
-
if @encrypt
|
|
167
|
+
if @encrypt
|
|
183
168
|
token = decrypt_token(token)
|
|
184
169
|
end
|
|
185
170
|
|
data/zooppa_api_v3.gemspec
CHANGED
|
@@ -5,7 +5,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
|
|
|
5
5
|
|
|
6
6
|
Gem::Specification.new do |spec|
|
|
7
7
|
spec.name = "zooppa_api_v3"
|
|
8
|
-
spec.version = '0.0.
|
|
8
|
+
spec.version = '0.0.3'
|
|
9
9
|
spec.authors = ["Ulrich Soeffing"]
|
|
10
10
|
spec.email = ["ulrich_soeffing@gmx.de"]
|
|
11
11
|
spec.description = "Wrapper for the Zooppa api v3"
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: zooppa_api_v3
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 0.0.
|
|
4
|
+
version: 0.0.3
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- Ulrich Soeffing
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2015-08-
|
|
11
|
+
date: 2015-08-11 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: bundler
|