Skip to content

Commit

Permalink
Bugfix for an unset method
Browse files Browse the repository at this point in the history
  • Loading branch information
andyjeffries committed Feb 26, 2018
1 parent 26f606f commit 6a561c4
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 2 deletions.
6 changes: 6 additions & 0 deletions CHANGELOG.md
@@ -1,5 +1,11 @@
# Changelog

## 1.5.7

Bugfix:

- Exceptions don't display a message if no method was set (internal exception?)

## 1.5.6

Feature:
Expand Down
3 changes: 2 additions & 1 deletion lib/flexirest/request.rb
Expand Up @@ -742,7 +742,8 @@ def initialize(options)
end

def message
"Sending #{@method.upcase} to '#{@request_url}' returned a #{@status} with the body of - #{@raw_response}"
method = @method.try(:upcase)
"Sending #{method} to '#{@request_url}' returned a #{@status} with the body of - #{@raw_response}"
end
end
class HTTPClientException < HTTPException ; end
Expand Down
2 changes: 1 addition & 1 deletion lib/flexirest/version.rb
@@ -1,3 +1,3 @@
module Flexirest
VERSION = "1.5.6"
VERSION = "1.5.7"
end

0 comments on commit 6a561c4

Please sign in to comment.