module Commons
Author: carlos@yellowme.mx
Description: The APIError class aids us in defining a standard interface for how we handle the errors in our API.
It has two main functions:
1. Hold details of the error thrown so it can be translated to one of the standard HTTP codes. 2. Provide a consistent way to "serialize" errors.
Attributes:
-
message: string, Holds a human friendly way to
describe the error.
-
status: integer, Denotes the HTTP status code.
-
error: string, Similar to message, but this
field is intended to show the error message from a raised error.
-
detail: Hash, Contains a more details about the
error.
Constants
- VERSION
Public Class Methods
secret_key_base()
click to toggle source
# File lib/commons/config.rb, line 7 def secret_key_base @secret_key_base || ENV["secret_key_base"] end
secret_key_base=(secret_key_base)
click to toggle source
# File lib/commons/config.rb, line 3 def secret_key_base=(secret_key_base) @secret_key_base = secret_key_base end