showing results for - "mongoose unique validator"
Russ
26 Apr 2017
1var mongoose = require('mongoose');var uniqueValidator = require('mongoose-unique-validator'); var mySchema = mongoose.Schema(/* put your schema definition here */);mySchema.plugin(uniqueValidator);