mints 0.0.31 → 0.0.32

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
  SHA256:
3
- metadata.gz: 15db76401dfa74546139b780363014a6502c2d10409f5ba7199d27c16b746d64
4
- data.tar.gz: 52ad33837204580f17ade75c3777dea6aea97903a508968a8bff0e5cb52f098e
3
+ metadata.gz: 8721bbc4b1c0b04f238ec5577801928582f5686030977cae483ef75a3625cf7e
4
+ data.tar.gz: d81e367b63a8ebfe67915ed60238ea0fedf98066f5b9de567efc3361fd9a056c
5
5
  SHA512:
6
- metadata.gz: 4ddb5dda74b294e5d351a6d700e93aa0120b3ef94622203c52020317768c23f88fa855ffe10463efda4bcbb558aca783d8107eb2bc5005102410a0cabcc7f9df
7
- data.tar.gz: 928bc2bfa825d822b08a7f30f9ea4575f43e4db1888d58caa07eac4a443372499b2b6f75dd4f45189ef9c2870d42ed0aadc9481a95c578e7b345e06f0f65a4d0
6
+ metadata.gz: 5904fa1556491f7794221aaf51fe313f92243d5f959879cf997b3efe26ffc900bf0d3a846ae7f31aff15639fd02eb23957920722ba2c060f18bd744cb88d444a
7
+ data.tar.gz: 29d380e6a824aedb240577b9ee40c29df92b62ec02090e690ec5537a5fb9fcda699b6eafea8ea52f9e07726aae3d4f7e6e85b5fb3f3b28fcc74232b3d400ced2
@@ -13,6 +13,6 @@ module ContactVouchers
13
13
  # data = { description: 'This is the transaction description', voucher_code: 'XAZWQ12MP' }
14
14
  # @data = @mints_contact.apply_voucher(1, data)
15
15
  def apply_voucher(order_id, data)
16
- @client.raw('post', "/ecommerce/orders/#{order_id}/voucher", nil, data_transform(data))
16
+ @client.raw('post', "/ecommerce/orders/#{order_id}/voucher", nil, data_transform(data), @contact_v1_url)
17
17
  end
18
18
  end
@@ -18,8 +18,11 @@ module ProxyControllersMethods
18
18
  # Returns the response returned by send_mints_request
19
19
  #
20
20
  def index(controller_type = nil)
21
+ host = @host.gsub('http://', '').gsub('https://', '')
22
+ host = host[0...-1] if host.end_with? '/'
23
+
21
24
  headers = {
22
- 'host' => @host.gsub('http://', '').gsub('https://', ''),
25
+ 'host' => host,
23
26
  'ApiKey' => @api_key.to_s,
24
27
  'Content-Type' => 'application/json',
25
28
  'Accept' => 'application/json'
@@ -50,7 +53,7 @@ module ProxyControllersMethods
50
53
  return render json: cached_response
51
54
  end
52
55
 
53
- send_mints_request(full_url, headers, true, time)
56
+ send_mints_request(full_url, headers, true, time: time)
54
57
  else
55
58
  send_mints_request(full_url, headers)
56
59
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: mints
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.31
4
+ version: 0.0.32
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ruben Gomez Garcia, Omar Mora, Luis Payan, Oscar Castillo, Fabian Garcia
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-05-02 00:00:00.000000000 Z
11
+ date: 2023-07-10 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: addressable