1
0
Fork 0
mirror of https://github.com/rest-client/rest-client.git synced 2022-11-09 13:49:40 -05:00

Fix spurious rubocop warning around Exceptions.

These exceptions already inherited from RestClient::Exception, but
rubocop couldn't tell the difference between that and ::Exception.
This commit is contained in:
Andy Brody 2017-07-05 01:09:48 -04:00
parent 06eafbf859
commit ee709b2fd8

View file

@ -148,7 +148,7 @@ module RestClient
end end
# Compatibility # Compatibility
class ExceptionWithResponse < Exception class ExceptionWithResponse < RestClient::Exception
end end
# The request failed with an error code not managed by the code # The request failed with an error code not managed by the code
@ -228,14 +228,14 @@ module RestClient
# The server broke the connection prior to the request completing. Usually # The server broke the connection prior to the request completing. Usually
# this means it crashed, or sometimes that your network connection was # this means it crashed, or sometimes that your network connection was
# severed before it could complete. # severed before it could complete.
class ServerBrokeConnection < Exception class ServerBrokeConnection < RestClient::Exception
def initialize(message = 'Server broke connection') def initialize(message = 'Server broke connection')
super nil, nil super nil, nil
self.message = message self.message = message
end end
end end
class SSLCertificateNotVerified < Exception class SSLCertificateNotVerified < RestClient::Exception
def initialize(message = 'SSL certificate not verified') def initialize(message = 'SSL certificate not verified')
super nil, nil super nil, nil
self.message = message self.message = message