Fix for catch error handling

This commit is contained in:
S_T_3_V_3
2023-08-14 22:41:51 +10:00
parent cc5465638e
commit 54b734dc10

View File

@ -1181,9 +1181,8 @@ const internalCertificate = {
try {
const parsedBody = JSON.parse(responseBody + '');
resolve(parsedBody);
}
catch {
logger.warn("Error");
} catch (err) {
logger.warn("Error: " + err.message);
logger.warn(`Status Code: ${res.statusCode}`);
logger.warn(`Failed to test HTTP challenge for domain ${domain}`, res);
resolve(undefined);