question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[Discussions] Obsoleting AddDataAnnotationsValidation and replacing with EnableDataAnnotationsValidation

See original GitHub issue

The extension method EditContextDataAnnotationsExtensions.AddDataAnnotationsValidation is being marked as obsolete. Developers should use the new extension method EditContextDataAnnotationsExtensions.EnableDataAnnotationsValidation instead.

The only difference between these two APIs is in their return values:

EditContext AddDataAnnotationsValidation(this EditContext editContext) { ... }

IDisposable EnableDataAnnotationsValidation(this EditContext editContext) { ... }

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

0reactions
msftbot[bot]commented, Jun 26, 2021

Thank you for contacting us. Due to a lack of activity on this discussion issue we’re closing it in an effort to keep our backlog clean. If you believe there is a concern related to the ASP.NET Core framework, which hasn’t been addressed yet, please file a new issue.

This issue will be locked after 30 more days of inactivity. If you still wish to discuss this subject after then, please create a new issue!

Read more comments on GitHub >

github_iconTop Results From Across the Web

AddDataAnnotationsValidation method obsoleted - .NET
The new API, EnableDataAnnotationsValidation , returns an IDisposable whose disposal can be used to remove the data-annotations validation ...
Read more >
Obsoleting AddDataAnnotationsValidation and replacing ...
The new API returns an IDisposable whose disposal can be used to remove the data annotations validation support from the EditContext . Reason ......
Read more >
How do I enable validation without using the ...
In FluentValidationValidator.cs, create a new validator component named FluentValidationValidator to replace DataAnnonationsValidator, and add the code below to ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found