Skip to content

Conversation

@driesvints
Copy link
Member

This change allows for multiple redirects in a comma separated list when adding them through the ClientController. It makes use of a custom validation rule which will separate the urls by the comma and run the url validator rule over each one individually.

Except for https://example.com individually, the value of https://example.com,https://example2.com would be allowed as well.

I took the approach of a custom validation rule because it seemed the most flexible in terms of implementing the custom logic. It allows for re-using Laravel's url validation rule.

Fixes #897

This change allows for multiple redirects in a comma separated list when adding them through the ClientController. It makes use of a custom validation rule which will separate the urls by the comma and run the url validator rule over each one individually.

Except for https://example.com individually, the value of https://example.com,https://example2.com would be allowed as well.

I took the approach of a custom validation rule because it seemed the most flexible in terms of implementing the custom logic. It allows for re-using Laravel's url validation rule.

Fixes #897
@taylorotwell taylorotwell merged commit ce37402 into laravel:7.0 Jan 11, 2019
@driesvints driesvints deleted the redirect-rule branch January 11, 2019 14:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants