mongoose field with the name type

You need to define the field using an object:

type: {type: String}

Leave a Comment