zumata 0.0.3 → 0.0.4

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: c728ece5dd181c10694ba630574588fdb15183c2
4
- data.tar.gz: 7c1971921aba9acfa290830bec7a22c630139b20
3
+ metadata.gz: 2161e2f108bebaf0c5c741fc399cdab134bf271e
4
+ data.tar.gz: 83a71789edf2881443f01677eeeb10fae5fb1619
5
5
  SHA512:
6
- metadata.gz: bc3242832f1ed303134de736028f35f60031ba745b627f7782437140e8f0030a80420ce19fdf0fc2c8b92d5dfde7bf4dd4346957a46bba5b542b58313b5a9427
7
- data.tar.gz: bac3373487a0c1a544eb36e70ef5194e0a4ce120ac743e737a6f911d3889dc022ad046c70b337cf40f519192dbb8448bc2bc2c217813c63ea1560969708831e1
6
+ metadata.gz: ff9cc787c7a5cc6b3f36c45a43f510dcda4db98c4b3a656f15307a84bc6b22149e441cb319dc8ac0c4a5250f9301dc060d1a7e689673e546e57ae764fe02a24c
7
+ data.tar.gz: cb073063f18a070d5050d4cc2ac0b2e885aab1d47a83dd2596427ad731604a4d4fbdf5ea3160e7e1cbcf03593131a1442d516f1db26ec159b34a211d5479795a
data/lib/zumata/client.rb CHANGED
@@ -51,14 +51,16 @@ module Zumata
51
51
 
52
52
  # raise InvalidRequestError unless valid_guest_params?(guest)
53
53
  # raise InvalidRequestError unless valid_payment_params?(payment)
54
-
55
- body_params = { api_key: opts[:api_key] || get_api_key,
54
+
55
+ api_key = opts[:api_key] || get_api_key
56
+ q_params = { api_key: api_key}
57
+ body_params = { api_key: api_key,
56
58
  booking_key: booking_key,
57
59
  affiliate_key: opts[:affiliate_key],
58
60
  guest: guest,
59
61
  payment: payment }
60
62
 
61
- res = self.class.post("#{@api_url}/book", body: body_params.to_json, headers: { 'Content-Type' => 'application/json' }, timeout: @timeout)
63
+ res = self.class.post("#{@api_url}/book", query: q_params, body: body_params.to_json, headers: { 'Content-Type' => 'application/json' }, timeout: @timeout)
62
64
 
63
65
  status_code = res.code.to_i
64
66
  raise Zumata::GeneralError, res.body unless VALID_STATUS_CODES.include?(status_code)
@@ -1,3 +1,3 @@
1
1
  module Zumata
2
- VERSION = "0.0.3"
2
+ VERSION = "0.0.4"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: zumata
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.3
4
+ version: 0.0.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonathan Gomez
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-10-02 00:00:00.000000000 Z
11
+ date: 2014-11-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler