mirror of
https://github.com/brianc/node-postgres.git
synced 2026-01-18 15:55:05 +00:00
Access Promise through global (#39)
This matches the proposed way in "bring your own promise".
This commit is contained in:
parent
2aed8bf7b3
commit
0f323999fc
2
index.js
2
index.js
@ -11,7 +11,7 @@ var Pool = module.exports = function (options, Client) {
|
||||
this.options = objectAssign({}, options)
|
||||
this.log = this.options.log || function () { }
|
||||
this.Client = this.options.Client || Client || require('pg').Client
|
||||
this.Promise = this.options.Promise || Promise
|
||||
this.Promise = this.options.Promise || global.Promise
|
||||
|
||||
this.options.max = this.options.max || this.options.poolSize || 10
|
||||
this.options.create = this.options.create || this._create.bind(this)
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user