From 1a632e34c41ecde48d63329bf60356aa9c6d613f Mon Sep 17 00:00:00 2001 From: tdotcspot Date: Tue, 3 Jan 2017 11:10:43 -0700 Subject: [PATCH] Set mongoose to use native promise library MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Mongoose’s default promise library has been deprecated causing a warning message stating that fact. This added line removes the warning and sets the promise library to use the native promise library. --- lib/index.js | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/index.js b/lib/index.js index c020ad5..a1e4a82 100644 --- a/lib/index.js +++ b/lib/index.js @@ -6,6 +6,7 @@ Hoek = require("hoek"); mongoose = require('mongoose'); + mongoose.Promise = global.Promise; Mixed = mongoose.Schema.Types.Mixed;