From 2b3c28c7a1b56c889b827ee75503754c525c784e Mon Sep 17 00:00:00 2001 From: Phil Kunz Date: Sun, 13 Jan 2019 00:50:43 +0100 Subject: [PATCH] fix(core): update --- ts/smartacme.classes.cert.ts | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/ts/smartacme.classes.cert.ts b/ts/smartacme.classes.cert.ts index e0f7911..1d70b6c 100644 --- a/ts/smartacme.classes.cert.ts +++ b/ts/smartacme.classes.cert.ts @@ -31,8 +31,10 @@ export class Cert extends plugins.smartdata.SmartDataDbDoc implements inte constructor(optionsArg: ICert) { super(); - Object.keys(optionsArg).forEach(key => { - this[key] = optionsArg[key]; - }); + if (optionsArg) { + Object.keys(optionsArg).forEach(key => { + this[key] = optionsArg[key]; + }); + } } }