Global prehooks for protecting read-only versions of website
(require("lib/middleware/mongoose/mongoose-middleware"))(schema, options)
Represents the plugin function middleware used for handling read-only website errors.
Parameters:
Name | Type | Description |
---|---|---|
schema |
Schema | The schema of the resource for which a modification is being attempted. |
options |
Object | The options used for modifying the execution of the middleware. |
Requires
- module:mongoose
- module:bin/errors/errors