Closed cpfergus1 closed 2 years ago
Thanks, @cpfergus1. The change is perfectly legit, but I'm not sure we want to merge changes into the deprecated frontend. cc @kennyadsl @aldesantis
We decided that we're going to keep merging changes until the gem is no longer part of the solidus meta-gem. So, we'll merge this one once the extensions are compatible.
Unlike the starter_frontend gem, this extension does not require solidus_auth_devise except for the sandbox - The updated methods will not be compatible unless solidus_auth_devise is included. When are we expecting to remove this extension from the solidus meta-gem? We may just want to continue to leave it untouched.
Hey @cpfergus1, as the only occurrence here has nothing to do with the sign-in process, can't we use Rails' redirect_back
/redirect_back_or_to
here?
Hey @cpfergus1, as the only occurrence here has nothing to do with the sign-in process, can't we use Rails'
redirect_back
/redirect_back_or_to
here?
Yes, it appears to work fine for this location. Thanks for pointing that out!
Description
Removes #redirect_back_or_default in favor of Rails #redirect_back and #redirect_back_or_to
Motivation and Context
Rails introduced redirect_back in rails 5+ and redirect_back_or_to in rails 7+. These methods should be utilized instead of the redirect method created by Soldius, which similarly replicates the functionality of the deprecated method. The method #redirect_back_or_default will be deprecated in Solidus PR #4533
How Has This Been Tested?
The current test suite covers the changes made in the PR
Types of changes
Bug fix (non-breaking change which fixes an issue)New feature (non-breaking change which adds functionality)Breaking change (fix or feature that would cause existing functionality to not work as expected)Checklist: