diff options
Diffstat (limited to 'app/node_modules/okresource/index.js')
| -rw-r--r-- | app/node_modules/okresource/index.js | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/app/node_modules/okresource/index.js b/app/node_modules/okresource/index.js index 055a24a..2eba03a 100644 --- a/app/node_modules/okresource/index.js +++ b/app/node_modules/okresource/index.js @@ -15,6 +15,7 @@ function OKResource(options) { throw new Error('No schema provided to OKResource'); if (!options.db) throw new Error('No DB provided to OKResource'); + var schema = options.schema; var type = options.type; this._db = options.db; // Define properties which are part of the API @@ -22,6 +23,10 @@ function OKResource(options) { value: schema, writable: false }); + Object.defineProperty(this, 'spec', { + value: schema.spec, + writable: false + }); Object.defineProperty(this, 'type', { value: type, writable: false |
