Skip to content

Commit

Permalink
Compare submitted confirmations against those required (#1526)
Browse files Browse the repository at this point in the history
Changes the logic to compare the number of submitted confirmations against the number required for Safe overview transactions awaiting confirmation:

- Change confirmation flag to compare number of submitted confirmations against the number of those required
  • Loading branch information
iamacook committed May 8, 2024
1 parent 533d5ec commit ff1f629
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/routes/safes/safes.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -208,7 +208,8 @@ export class SafesService {
}): number {
return args.transactions.reduce(
(acc, { confirmationsRequired, confirmations }) => {
const isConfirmed = confirmationsRequired === 0;
const isConfirmed =
!!confirmations && confirmations.length >= confirmationsRequired;
const isSignable =
!isConfirmed &&
!confirmations?.some((confirmation) => {
Expand Down

0 comments on commit ff1f629

Please sign in to comment.