diff --git a/src/factory.ts b/src/factory.ts index 06ee3fa..41ed06a 100644 --- a/src/factory.ts +++ b/src/factory.ts @@ -209,7 +209,7 @@ function getModelBufferContents(model: BundleUnit): PartitionedBundle { */ async function readCertificatesFromOptions(options: Certificates): Promise { - if (!isValid(options, "certificatesSchema")) { + if (!(options && Object.keys(options).length && isValid(options, "certificatesSchema"))) { throw new Error("Unable to create Pass: certificates schema validation failed."); }