Skip to content

Commit

Permalink
Merge pull request Automattic#1926 from yorkie/patch-1
Browse files Browse the repository at this point in the history
expose connection states for user-land
  • Loading branch information
aheckmann committed Feb 22, 2014
2 parents 8fd25ac + f042175 commit 7d976b5
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions lib/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ var Schema = require('./schema')
, SchemaType = require('./schematype')
, VirtualType = require('./virtualtype')
, SchemaDefaults = require('./schemadefault')
, STATES = require('./connectionstate')
, Types = require('./types')
, Query = require('./query')
, Promise = require('./promise')
Expand Down Expand Up @@ -62,6 +63,12 @@ function Mongoose () {
this.createConnection(); // default connection
};

/**
* Expose connection states for user-land
*
*/
Mongoose.prototype.STATES = STATES;

/**
* Sets mongoose options
*
Expand Down

0 comments on commit 7d976b5

Please sign in to comment.