Added constructor check on certificates to avoid an error if a pass is created using PKPass.from, without specifying the certificates

This commit is contained in:
Alexander Cerutti
2021-11-14 00:47:37 +01:00
parent f430bf1515
commit 5651ce69a5

View File

@@ -157,8 +157,10 @@ export default class PKPass extends Bundle {
Object.assign(this[propsSymbol], overridesValidation); Object.assign(this[propsSymbol], overridesValidation);
} }
if (certificates) {
this.certificates = certificates; this.certificates = certificates;
} }
}
/** /**
* Allows changing the certificates, if needed. * Allows changing the certificates, if needed.