jeremyevans / rodauth

Ruby's Most Advanced Authentication Framework
http://rodauth.jeremyevans.net
MIT License
1.65k stars 95 forks source link

Update require login redirect when login route changes #396

Closed janko closed 4 months ago

janko commented 4 months ago

When login feature is enabled, it's expected that requiring login will redirect to the login page. This won't be the case if login_route changes. I thought it would be convenient to have it automatically match, so that the developer doesn't have to also update require_login_redirect in that case.

janko commented 4 months ago

I added the requested change.

jeremyevans commented 4 months ago

My apologies, I didn't realize when I requested the change that the redirect call was in a different feature (base instead of login). So your original patch did not redefine a method. Your original patch was correct and I'll merge that.

jeremyevans commented 4 months ago

Cherry-picked as 0869be21335c6892792922e878dd0b5b82e2fd33