almapi 0.1.12 → 0.1.14
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/almapi/almapi.rb +2 -3
- data/lib/almapi/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b583eab87ae84d520b3ea4e9e7751338240e34dfab0dc2e4a1b8c79a47ad4b4f
|
4
|
+
data.tar.gz: 194b63c90551827de9223d87101e405c7dcd0a1deaab10c8b533376d9e885892
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 684c21017a843823c207493916369211df8c826e53e3f24a91bd779381f2864fee76889d89e982e2ea7a9cd014bb91361b582c9c09da8e6efdd7973e5ac77dbb
|
7
|
+
data.tar.gz: 5484e804fc5015968ecbc14e4452820b9a22d75f45ce37c35cb72e42ebbe811c029fe9453fbc5872e487c9bb64b47ce24ee82d89111a08ef26f290ef6ed6ad7d
|
data/lib/almapi/almapi.rb
CHANGED
@@ -93,9 +93,8 @@ module Almapi
|
|
93
93
|
#
|
94
94
|
# @param resource [String] mandatory : the part of the URI specifying the access point.
|
95
95
|
# Must not include "?" for it adds "?apikey" automatically.
|
96
|
-
# @param data [String] : an XML string containing data to put.
|
97
96
|
# @return [Response] : the resulting response. If error occurs, raises an AlmapiError
|
98
|
-
def delete(resource
|
97
|
+
def delete(resource)
|
99
98
|
url_api = "#{@uri_base}#{resource}"
|
100
99
|
puts "[Almapi::Api.delete] INFO URL #{url_api}"
|
101
100
|
handle_response(@conn.delete(url_api), "DELETE")
|
@@ -110,7 +109,7 @@ module Almapi
|
|
110
109
|
# @return [Response || AlmapiError] : the resulting response if the API call succeeded, else AlmapiError
|
111
110
|
def handle_response(response, method)
|
112
111
|
case response.status
|
113
|
-
when 200
|
112
|
+
when 200, 204
|
114
113
|
# Success
|
115
114
|
response
|
116
115
|
else
|
data/lib/almapi/version.rb
CHANGED