bwgjoseph / mongoose-vs-ottoman

feature comparison between mongoose and ottoman
0 stars 1 forks source link

validation error message not consistent #72

Closed bwgjoseph closed 3 years ago

bwgjoseph commented 3 years ago

Hi,

While testing createMany API, I noticed that the error message is not consistent

const response = await Airplane.createMany({ callsign: 'Hawk', capacity: 1000 });
// this is the response
{
  "status": "FAILURE",
  "message": {
    "success": 0,
    "match_number": 1,
    "errors": [
      {
        "payload": {
          "callsign": "Hawk",
          "capacity": 1000
        },
        "status": "FAILURE",
        "exception": "ValidationError",
        "message": "Property name is required, Property 'capacity' is more than the maximum allowed value of '550', Property model is required"
      }
    ]
  }
}

Notice that only capacity and value has the single quote around the property name and value?

Related to #41

httpJunkie commented 3 years ago

Fixed w/ alpha 29