merge
This commit is contained in:
commit
f5126ad8ed
|
@ -1,10 +1,15 @@
|
||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
var url = require('url');
|
var url = require('url');
|
||||||
var PromiseA = require('bluebird');
|
|
||||||
var sni = require('sni');
|
var sni = require('sni');
|
||||||
var Packer = require('proxy-packer');
|
var Packer = require('proxy-packer');
|
||||||
var PortServers = {};
|
var PortServers = {};
|
||||||
|
var PromiseA;
|
||||||
|
try {
|
||||||
|
PromiseA = require('bluebird');
|
||||||
|
} catch(e) {
|
||||||
|
PromiseA = global.Promise;
|
||||||
|
}
|
||||||
|
|
||||||
function timeoutPromise(duration) {
|
function timeoutPromise(duration) {
|
||||||
return new PromiseA(function (resolve) {
|
return new PromiseA(function (resolve) {
|
||||||
|
|
Loading…
Reference in New Issue