Class: Ibrain::Auth::FailureApp
- Inherits:
-
Devise::FailureApp
- Object
- Devise::FailureApp
- Ibrain::Auth::FailureApp
- Includes:
- ActionController::Helpers
- Defined in:
- lib/ibrain/auth/failure_app.rb
Instance Method Summary collapse
Instance Method Details
#json_error_response ⇒ Object
10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
# File 'lib/ibrain/auth/failure_app.rb', line 10 def json_error_response self.status = 401 self.content_type = "application/json" self.response_body = { errors: [{ message: , extensions: { code: 401, exception: { stacktrace: [] } } }], message: , data: nil }.to_json end |
#respond ⇒ Object
6 7 8 |
# File 'lib/ibrain/auth/failure_app.rb', line 6 def respond json_error_response end |