Skip to content

Commit

Permalink
Merge pull request #4293 from LibreSign/fix/prevent-js-error-when-add…
Browse files Browse the repository at this point in the history
…-new-signer

fix: prevent error when add new signer
  • Loading branch information
vitormattos authored Jan 13, 2025
2 parents dfb1d43 + 08bc35a commit 9f2cbfd
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions src/store/files.js
Original file line number Diff line number Diff line change
Expand Up @@ -199,6 +199,9 @@ export const useFilesStore = function(...args) {
},
signerUpdate(signer) {
this.addIdentifierToSigner(signer)
if (!this.getFile().signers?.length) {
this.getFile().signers = []
}
// Remove if already exists
for (let i = this.getFile().signers.length - 1; i >= 0; i--) {
if (this.getFile().signers[i].identify === signer.identify) {
Expand Down

0 comments on commit 9f2cbfd

Please sign in to comment.