app/controllers/nyauth/sessions_controller.rb in nyauth-0.2.4 vs app/controllers/nyauth/sessions_controller.rb in nyauth-0.2.5

- old
+ new

@@ -1,9 +1,11 @@ module Nyauth class SessionsController < ApplicationController include Nyauth::ApplicationConcern include Nyauth::ClientConcern + include Nyauth::SessionConcern + before_action -> { require_authentication! as: client_name } allow_everyone only: [:new, :create] respond_to :html, :json before_action :set_session_service def new @@ -14,10 +16,10 @@ respond_with @session_service, location: Nyauth.configuration.redirect_path_after_sign_in.call(client_name) || main_app.root_path end def destroy sign_out - respond_with @session_service, location: Nyauth.configuration.redirect_path_after_sign_out.call(client_name) || new_session_path + respond_with @session_service, location: Nyauth.configuration.redirect_path_after_sign_out.call(client_name) || new_session_path_for(client_name) end private def set_session_service