-
Notifications
You must be signed in to change notification settings - Fork 1.6k
Correcting and clarifying RegularExpressionAttribute.IsValid #8165
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
base: main
Are you sure you want to change the base?
Conversation
* `RegularExpressionValidator.IsValid` does not throw `ValidationException` * Adding remark that `Object?` values are converted to a `String` using `Convert.ToString` which I found a tad surprising (as instead I expected it to throw if a non-null, non-string argument was passed).
Adding remark about null and empty strings.
Tagging subscribers to this area: @dotnet/area-system-text-regularexpressions Issue DetailsSummary
Fixes #8164
|
Docs Build status updates of commit 161a4da:
|
File | Status | Preview URL | Details |
---|---|---|---|
xml/System.ComponentModel.DataAnnotations/RegularExpressionAttribute.xml | View | Details |
xml/System.ComponentModel.DataAnnotations/RegularExpressionAttribute.xml
- Line 0, Column 0: [Warning: xref-not-found]
Cross reference not found: 'System.Convert.ToString(object?,IFormatProvider?)'.
For more details, please refer to the build report.
If you see build warnings/errors with permission issues, it might be due to single sign-on (SSO) enabled on Microsoft's GitHub organizations. Please follow instructions here to re-authorize your GitHub account to Docs Build.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
Note: Your PR may contain errors or warnings unrelated to the files you changed. This happens when external dependencies like GitHub alias, Microsoft alias, cross repo links are updated. Please use these instructions to resolve them.
For any questions, please:
- Try searching the docs.microsoft.com contributor guides
- Post your question in the Docs support channel
Docs Build status updates of commit 04da9eb: ✅ Validation status: passed
For more details, please refer to the build report. Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report. For any questions, please:
|
Tagging subscribers to this area: @ajcvickers Issue DetailsSummary
Fixes #8164
|
Summary
RegularExpressionValidator.IsValid
does not throwValidationException
Object?
values are converted to aString
usingConvert.ToString
which I found a tad surprising (as instead I expected it to throw if a non-null, non-string argument was passed).Fixes #8164