From 5987cc6fb0970f0d426d931116fcabed83a3a58b Mon Sep 17 00:00:00 2001 From: Prathamesh Sonpatki Date: Fri, 7 Sep 2018 13:19:42 +0530 Subject: [PATCH] #513 Added raise: false to fix the issues related to autoloading - Addresses https://github.com/bigbinary/acehelp/issues/517 --- .../devise_token_auth/omniauth_callbacks_controller.rb | 2 +- app/controllers/devise_token_auth/passwords_controller.rb | 2 +- app/controllers/devise_token_auth/registrations_controller.rb | 2 +- app/controllers/devise_token_auth/unlocks_controller.rb | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/controllers/devise_token_auth/omniauth_callbacks_controller.rb b/app/controllers/devise_token_auth/omniauth_callbacks_controller.rb index e3eb5ba64..64cd95798 100644 --- a/app/controllers/devise_token_auth/omniauth_callbacks_controller.rb +++ b/app/controllers/devise_token_auth/omniauth_callbacks_controller.rb @@ -4,7 +4,7 @@ module DeviseTokenAuth class OmniauthCallbacksController < DeviseTokenAuth::ApplicationController attr_reader :auth_params skip_before_action :set_user_by_token, raise: false - skip_after_action :update_auth_header + skip_after_action :update_auth_header, raise: false # intermediary route for successful omniauth authentication. omniauth does # not support multiple models, so we must resort to this terrible hack. diff --git a/app/controllers/devise_token_auth/passwords_controller.rb b/app/controllers/devise_token_auth/passwords_controller.rb index e6ceb2397..75a44dcfc 100644 --- a/app/controllers/devise_token_auth/passwords_controller.rb +++ b/app/controllers/devise_token_auth/passwords_controller.rb @@ -3,7 +3,7 @@ module DeviseTokenAuth class PasswordsController < DeviseTokenAuth::ApplicationController before_action :set_user_by_token, only: [:update] - skip_after_action :update_auth_header, only: [:create, :edit] + skip_after_action :update_auth_header, only: [:create, :edit], raise: false # this action is responsible for generating password reset tokens and # sending emails diff --git a/app/controllers/devise_token_auth/registrations_controller.rb b/app/controllers/devise_token_auth/registrations_controller.rb index 5b9271707..fdcabec83 100644 --- a/app/controllers/devise_token_auth/registrations_controller.rb +++ b/app/controllers/devise_token_auth/registrations_controller.rb @@ -5,7 +5,7 @@ class RegistrationsController < DeviseTokenAuth::ApplicationController before_action :set_user_by_token, only: [:destroy, :update] before_action :validate_sign_up_params, only: :create before_action :validate_account_update_params, only: :update - skip_after_action :update_auth_header, only: [:create, :destroy] + skip_after_action :update_auth_header, only: [:create, :destroy], raise: false def create build_resource diff --git a/app/controllers/devise_token_auth/unlocks_controller.rb b/app/controllers/devise_token_auth/unlocks_controller.rb index eda8d84d7..d397133fc 100644 --- a/app/controllers/devise_token_auth/unlocks_controller.rb +++ b/app/controllers/devise_token_auth/unlocks_controller.rb @@ -2,7 +2,7 @@ module DeviseTokenAuth class UnlocksController < DeviseTokenAuth::ApplicationController - skip_after_action :update_auth_header, only: [:create, :show] + skip_after_action :update_auth_header, only: [:create, :show], raise: false # this action is responsible for generating unlock tokens and # sending emails