Skip to content

Commit

Permalink
documenting integration with deleted
Browse files Browse the repository at this point in the history
  • Loading branch information
weisjohn committed Jul 27, 2015
1 parent bc3c00c commit 21c9ced
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,8 @@ mp(users, data, function(err, results) {

`callback` receives a `results` object of with three numbers: `added`, `failed`, `skipped` and a `records` array, containing the inserted records.

`validate` indicates whether schema validation should occur before inserting. For example, object reference validators which ensure the referenced document exists may prevent data from being loaded (i.e. cylical dependencies). To prevent this, invoke with the value of `false` to temporarily suspend the validators. After loading the data, the schema validation will be set to it's previous value. If no value is specified, `mongoose-prime` will not modify the model's validation settings. (cf. [`#validateBeforeSave`](http://mongoosejs.com/docs/guide.html#validateBeforeSave))
`validate` indicates whether schema validation should occur before inserting. For example, object reference validators which ensure the referenced document exists may prevent data from being loaded (i.e. cylical dependencies). To prevent this, invoke with the value of `false` to temporarily suspend the validators. After loading the data, the schema validation will be set to it's previous value. If no value is specified, `mongoose-prime` will not modify the model's validation settings. (cf. [`#validateBeforeSave`](http://mongoosejs.com/docs/guide.html#validateBeforeSave))

### integration

`mongoose-prime` plays nicely with [`mongoose-deleted`](https://www.npmjs.com/package/mongoose-deleted).

0 comments on commit 21c9ced

Please sign in to comment.