Exception: Pastee::Errors::UnknownError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/pastee/errors.rb

Overview

Error for an unrecognized error code from the API.

Instance Method Summary collapse

Constructor Details

#initialize(error_code, error_msg) ⇒ UnknownError

Returns a new instance of UnknownError.



5
6
7
8
# File 'lib/pastee/errors.rb', line 5

def initialize(error_code, error_msg)
  @error_code = error_code
  @error_msg = error_msg
end

Instance Method Details

#messageObject



10
11
12
# File 'lib/pastee/errors.rb', line 10

def message
  "Error code #{@error_code} (unknown): #{@error_msg}. Please report this unknown error to the developers of the pastee gem."
end