Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow #try_spree_current_user to search for private methods #2694

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions core/lib/spree/core/controller_helpers/auth.rb
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,10 @@ def store_location
def try_spree_current_user
# This one will be defined by apps looking to hook into Spree
# As per authentication_helpers.rb
if respond_to?(:spree_current_user)
if respond_to?(:spree_current_user, true)
spree_current_user
# This one will be defined by Devise
elsif respond_to?(:current_spree_user)
elsif respond_to?(:current_spree_user, true)
current_spree_user
end
end
Expand Down