v2.7.1: workaround for bug in some versions of greenlock-express

This commit is contained in:
AJ ONeal 2019-04-01 14:18:33 -06:00
parent e60b4356c1
commit df0f870665
2 changed files with 7 additions and 3 deletions

View File

@ -434,7 +434,9 @@ module.exports.create = function (gl) {
, checkAsync: function (args) {
var copy = utils.merge(args, gl);
// if approveDomains doesn't set subject, we set it here
copy.subject = copy.subject || copy.domains[0];
if (!(copy.domains && copy.domains.length)) { copy.domains = [ copy.subject || copy.domain ].filter(Boolean); }
if (!copy.subject) { copy.subject = copy.domains[0]; }
if (!copy.domain) { copy.domain = copy.domains[0]; }
args = utils.tplCopy(copy);
// returns pems
@ -456,7 +458,9 @@ module.exports.create = function (gl) {
, getAsync: function (args) {
var copy = utils.merge(args, gl);
// if approveDomains doesn't set subject, we set it here
copy.subject = copy.subject || copy.domains[0];
if (!(copy.domains && copy.domains.length)) { copy.domains = [ copy.subject || copy.domain ].filter(Boolean); }
if (!copy.subject) { copy.subject = copy.domains[0]; }
if (!copy.domain) { copy.domain = copy.domains[0]; }
args = utils.tplCopy(copy);
if (args.certificate && args.certificate.privkey && args.certificate.cert && args.certificate.chain) {

View File

@ -1,6 +1,6 @@
{
"name": "greenlock",
"version": "2.7.0",
"version": "2.7.1",
"description": "Let's Encrypt for node.js on npm",
"main": "index.js",
"files": [