-
Notifications
You must be signed in to change notification settings - Fork 527
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
fix: default cors plugin formdata validation error #1855
Conversation
Deploy preview for apisix-dashboard ready! Built with commit 07b9a7c |
Codecov Report
@@ Coverage Diff @@
## master #1855 +/- ##
==========================================
+ Coverage 72.10% 72.47% +0.36%
==========================================
Files 125 125
Lines 2947 2950 +3
Branches 711 712 +1
==========================================
+ Hits 2125 2138 +13
+ Misses 822 812 -10
Flags with carried forward coverage won't be shown. Click here to find out more.
Continue to review full report at Codecov.
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
/lgtm
Thanks.
Please answer these questions before submitting a pull request, or your PR will get closed.
Why submit this pull request?
What changes will this PR take into?
when I submitted default cors plugin configure in form mode, a validation error occured:
the error shows that
allow_origins_by_regex
should have at least 1 character.schema of
cors
plugin:shows that
allow_origins_by_regex
is not a required item, but when it configured, it should be at least 1 character.the default post data is:
the mistake is
"allow_origins_by_regex": [""]
, why the value is [""]? In order to make UI better to use, we set defaultallow_origins_by_regex
empty to have one input box in the page.omit
allow_origins_by_regex
when it is not configuredChecklist: