Add whereUlid(param) support for routing #45372
Merged
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Allows route()->whereUlid() support for routing, which currently only allows for whereUuid().
I didn't add any tests because:
(a) the regex is simple
(b) there were no existing test for the other regex params that I found to build off of
(c) there may also be discussion as to whether lower-case should be supported, or whether the regex should be fine-tuned to support actually generatable ULID's (there's further refinement that's technically possible, but there's a question of whether you hit diminishing returns)