Background: Rails 7 introduces a redirect_back_or_to method which is used by redirect_back under the hood. Sorcery has a same name method redirect_back_or_to since ... a long time ago.
Because invisible_captcha will use redirect_back when a on_timestamp_spam is triggered, if Sorcery is also used in the project, it will overwrite the Rails redirect_back_or_to method, so invisible_captcha will redirect the user to root url, instead of displaying a "Sorry, that was too quick" alert.
The same name method issue is known to the Sorcery maintainer, to temporarily solve the issue, check this: #296
Background: Rails 7 introduces a
redirect_back_or_to
method which is used byredirect_back
under the hood. Sorcery has a same name methodredirect_back_or_to
since ... a long time ago.Because invisible_captcha will use
redirect_back
when a on_timestamp_spam is triggered, if Sorcery is also used in the project, it will overwrite the Railsredirect_back_or_to
method, so invisible_captcha will redirect the user to root url, instead of displaying a "Sorry, that was too quick" alert.The same name method issue is known to the Sorcery maintainer, to temporarily solve the issue, check this: #296