Closed Tofandel closed 1 month ago
Thanks @Tofandel, I agree however this PR doesn't actually change the default config value, right? We can document that it can be set to null for now to get the new default behavior and make the config breaking change in Twill 4.
No it doesn't, I forgot about it, the config is set by default there https://github.com/area17/twill/blob/3.x/config/twill.php#L175, I and so this PR doesn't apply unless explicitely set to null, don't think changing it to null would be considered a breaking change would it?
If we set it to null I'm afraid the case where one is using both an admin domain and a path at the same time would break. It's very much an edge case but I think the mistake was to release Twill 3 with the path approach as the default without updating the configuration, so we could technically consider this a bug I guess.
admin domain and a path at the same time
Not sure I understand the edge case? If we set just twill.auth_login_redirect_path
to null, all the other instances of usage are already replaced by the PR, so then it just uses the new default behavior
You're right.
Do we need a new helpers class for this though? I'm curious why you didn't put this under TwillRoutes
.
TwillRoutes
is a good place for it, I didn't see it, I just wanted to create a Route helper to prepare for the moving of the https://github.com/area17/twill/blob/3.x/src/Helpers/routes_helpers.php to it, but I guess since there is only one method in it, it can also move to that class, which already fits well for that purpose
Fixes #2568