lib/ldp/client/methods.rb in ldp-0.6.1 vs lib/ldp/client/methods.rb in ldp-0.6.2
- old
+ new
@@ -113,10 +113,10 @@
private
def check_for_errors resp
resp.tap do |resp|
- unless resp.success?
+ unless resp.status < 400
raise case resp.status
when 400
if resp.env.method == :head
# If the request was a HEAD request (which only retrieves HTTP headers),
# re-run it as a GET in order to retrieve a message body (which is passed on as the error message)