Reputation: 17
method in my my controller is
def userDirections
if user_signed_in?
redirect_to admin_user_path(admin_user_url)
else
redirect_to new_user_session_path
end
end
Upvotes: 0
Views: 58
Reputation: 86
this should work
def userDirections
if user_signed_in?
redirect_to admin_user_path(current_user)
else
redirect_to new_user_session_path
end
end
Upvotes: 2