Sha256: 81ab7c184d8435f31cff24aaeeda5e871d3171570f75ee99e5a771927e1b5719

Contents?: true

Size: 393 Bytes

Versions: 6

Compression:

Stored size: 393 Bytes

Contents

class ActiveResource::ConnectionError
  # TODO: get rid of monkey patching
  def to_s
    message = "Failed."
    message << "  Response code = #{response.code}." if response.respond_to?(:code)
    message << "  Response message = #{response.message}." if response.respond_to?(:message)
    message << "  Response body = #{response.body}." if response.respond_to?(:body)
    message
  end
end

Version data entries

6 entries across 6 versions & 1 rubygems

Version Path
mailroute-0.0.6 lib/mailroute/extensions/active_resource/better_connection_error.rb
mailroute-0.0.5 lib/mailroute/extensions/active_resource/better_connection_error.rb
mailroute-0.0.4 lib/mailroute/extensions/active_resource/better_connection_error.rb
mailroute-0.0.3 lib/mailroute/extensions/active_resource/better_connection_error.rb
mailroute-0.0.2 lib/mailroute/extensions/active_resource/better_connection_error.rb
mailroute-0.0.1 lib/mailroute/extensions/active_resource/better_connection_error.rb