quickmail 0.17.0 → 0.18.0

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: 7c230f03c9c4a768d9c56d94a37396841d47015b79aaf6ef96b1e46e79d3773e
4
- data.tar.gz: 97a992b510201d1473f053d46d9b6909d41af62bd2c3aa9ccacb272d2d9e0fb3
3
+ metadata.gz: 7c32da1d6cf69625dac15061c22e1d25ecd2bbba5bb68cbf3a2e8e2b74e9b268
4
+ data.tar.gz: 2b4573f5bf66172fa863be80eb63117846e6262dde7408ebf061658990feb00b
5
5
  SHA512:
6
- metadata.gz: 82f88eab0bcf157a92427aa8f9e32f91b7741e2087b22dad758b100f2122fa0ac25eac92005748054f4aa954bb9571e74b8b5e21a84a0acb8fb6a92a0ba6cb5c
7
- data.tar.gz: a50a4901fea7de01cdd1bc3a3ddc393043a2bdd9e4218aed6a964a6f07866cd343fa2628853c930ae731efeb870e5e326603754c3447b136384195ccb34b4ecb
6
+ metadata.gz: 28d725bb5df5dfb1026894bcb04d382303e8cfad1f0c20345e8af75d02b9ce70c119df0171ba0183d7f8c276eb10d6b9ffd651a733faf1b6cef27c183a944a8a
7
+ data.tar.gz: aa81d960accd74e0508f40b8d623f59ec9580cdc090dd9733385503baec90e05df0354637c7146a20db6178c12e138450141883a80b84c596a271e5da7eee1d5
@@ -75,15 +75,16 @@ module Quickmail
75
75
  payload: payload.to_json,
76
76
  headers: headers
77
77
  }).execute do |response, request, result|
78
- if response.code != 201 || response.code != 200
78
+ if response.code == 201 || response.code == 200
79
+ str_response = response.to_str
80
+ str_response.blank? ? '' : JSON.parse(str_response)
81
+ else
79
82
  raise ApiRequestError.new(
80
83
  response_code: response.code,
81
84
  response_headers: response.headers,
82
85
  response_body: response.to_str
83
86
  )
84
87
  end
85
- str_response = response.to_str
86
- str_response.blank? ? '' : JSON.parse(str_response)
87
88
  end
88
89
  end
89
90
 
@@ -1,3 +1,3 @@
1
1
  module Quickmail
2
- VERSION = "0.17.0"
2
+ VERSION = "0.18.0"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: quickmail
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.17.0
4
+ version: 0.18.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Tom Dallimore