update signatureCount to init in constructor
This commit is contained in:
@@ -5,7 +5,7 @@ class App {
|
||||
this.pdfKit = null
|
||||
this.currentDocument = envelopeReceiver.envelope.documents[0]
|
||||
this.currentReceiver = envelopeReceiver.receiver
|
||||
this.signatureCount = 0;
|
||||
this.signatureCount = envelopeReceiver.envelope.documents[0].elements.length;
|
||||
this.envelopeReceiver = envelopeReceiver;
|
||||
this.documentBytes = documentBytes;
|
||||
this.licenseKey = licenseKey;
|
||||
@@ -36,7 +36,6 @@ class App {
|
||||
|
||||
// Load annotations into PSPDFKit
|
||||
try {
|
||||
this.signatureCount = this.currentDocument.elements.length
|
||||
await createAnnotations(this.currentDocument, this.pdfKit)
|
||||
} catch (e) {
|
||||
console.error("Error loading annotations:", e);
|
||||
|
||||
Reference in New Issue
Block a user