class GrapeTokenAuth::OmniAuthFailureHTML

Constants

FAILURE_MESSAGE

Attributes

error_message[R]

Public Class Methods

new(error_message) click to toggle source
# File lib/grape_token_auth/omniauth/omniauth_failure_html.rb, line 6
def initialize(error_message)
  @error_message = error_message
end

Public Instance Methods

auth_origin_url() click to toggle source
# File lib/grape_token_auth/omniauth/omniauth_failure_html.rb, line 10
def auth_origin_url
  "/#?error=#{error_message}"
end
json_post_data() click to toggle source
# File lib/grape_token_auth/omniauth/omniauth_failure_html.rb, line 14
def json_post_data
  {
    'message' => FAILURE_MESSAGE,
    'error'   => error_message
  }.to_json
end