Skip to content

Commit c040695

Browse files
committed
Make bluebird as default promise overriding ES6 promise
Closes kunalkapadia#48
1 parent c76f466 commit c040695

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

index.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,13 @@
1-
import Promise from 'bluebird';
21
import mongoose from 'mongoose';
32
import util from 'util';
43
import config from './config/env';
54
import app from './config/express';
65

76
const debug = require('debug')('express-mongoose-es6-rest-api:index');
87

8+
// make bluebird default Promise
9+
Promise = require('bluebird'); // eslint-disable-line no-global-assign
10+
911
// plugin bluebird promise in mongoose
1012
mongoose.Promise = Promise;
1113

0 commit comments

Comments
 (0)