Exception: HumanError::Errors::InvalidUsernameOrPasswordError

Inherits:
RequestError
  • Object
show all
Includes:
AuthenticationError
Defined in:
lib/human_error/errors/authentication_errors/invalid_username_or_password_error.rb

Instance Attribute Summary collapse

Attributes included from HumanError::Error

#api_error_documentation_url, #api_version, #code, #knowledgebase_article_id, #knowledgebase_url, #message

Instance Method Summary collapse

Methods inherited from RequestError

#as_json

Methods included from HumanError::Error

#customer_support_uri, #developer_documentation_uri, included, #initialize, #to_json, #to_s

Instance Attribute Details

#usernameObject

Returns the value of attribute username.



9
10
11
# File 'lib/human_error/errors/authentication_errors/invalid_username_or_password_error.rb', line 9

def username
  @username
end

Instance Method Details

#developer_detailsObject



20
21
22
# File 'lib/human_error/errors/authentication_errors/invalid_username_or_password_error.rb', line 20

def developer_details
  { username: username, password: '[FILTERED]' }
end

#developer_messageObject



15
16
17
18
# File 'lib/human_error/errors/authentication_errors/invalid_username_or_password_error.rb', line 15

def developer_message
  'Either the username or password passed in or this request is invalid.  Please ' \
  'double-check and try again.'
end

#friendly_messageObject



24
25
26
# File 'lib/human_error/errors/authentication_errors/invalid_username_or_password_error.rb', line 24

def friendly_message
  'Either your email or password is incorrect.  Please double-check and try again.'
end

#http_statusObject



11
12
13
# File 'lib/human_error/errors/authentication_errors/invalid_username_or_password_error.rb', line 11

def http_status
  401
end