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.

The following errors were detected during validation.\r\n - model is null

See original GitHub issue
            var data = { 'Id': ctrl.id };
            $http.delete('../api/Provider', data)

        [HttpDelete]
        public IHttpActionResult DeleteProvider(Identificator model)
        {

    public class Identificator
    {
        public long Id { get; set; }

return mentioned error

                var data = { 'Id': ctrl.id, 'Name': ctrl.name, 'Email': ctrl.email, 'Guid': ctrl.guid };
                $http.put('../api/Provider', data)

works

Issue Analytics

  • State:closed
  • Created 7 years ago
  • Comments:13 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
hikalkancommented, Sep 22, 2016

Please check logs to see the error.

0reactions
dsalodkicommented, Sep 22, 2016

hikalkan Thank you for advise. Solution was

                $http({
                    method: 'DELETE',
                    url: '../api/Provider',
                    headers: {
                        'Content-Type': 'application/json'
                    },
                    data: { Id: ctrl.id }
                })

I have added header and [DisableValidation] [HttpDelete] public IHttpActionResult DeleteProvider([FromBody]ProviderListDto data) {

Read more comments on GitHub >

github_iconTop Results From Across the Web

One or more validation errors were detected during model ...
I have a Manufacturer table and a ManufacturerModel table. My cascading dropdown consists of a user selecting a manufacturer first and then ...
Read more >
Always get invalid validation in ASPNETZero Core V5 #4264
Hi, I always get the problem of validation in ASPNET Zero. Here are my ... "details": "The following errors were detected during validation....
Read more >
REST API for Knowledge Advanced in B2C Service
The error occurs when no values are found for the field path, original parameters, and parameter values predicates in the criteria query.
Read more >
VMware ESXi 7.0 Update 3f Release Notes
The issue occurs when vSAN data traffic and witness traffic use different vmknics. In the vSphere Client. you see the following error message...
Read more >
Error codes reference list
List of all Electronic Data Interchange ( EDI ) error codes including electronic release ( ACROSS ), Release Notification System ( RNS ) ......
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