allow for synchronous return
This commit is contained in:
parent
73f2051188
commit
08a38a71f1
2
index.js
2
index.js
|
@ -478,7 +478,7 @@ Greenlock.create = function (gl) {
|
||||||
}
|
}
|
||||||
try {
|
try {
|
||||||
if (1 === gl.approveDomains.length) {
|
if (1 === gl.approveDomains.length) {
|
||||||
return gl.approveDomains(opts).then(onApproved, onRejected);
|
return PromiseA.resolve(gl.approveDomains(opts)).then(onApproved, onRejected);
|
||||||
} else if (2 === gl.approveDomains.length) {
|
} else if (2 === gl.approveDomains.length) {
|
||||||
gl.approveDomains(opts, onMaybe);
|
gl.approveDomains(opts, onMaybe);
|
||||||
} else {
|
} else {
|
||||||
|
|
Loading…
Reference in New Issue