Confirm before executing.
isOwner[msg.sender]confirmed[id][msg.sender] = truetxs[id].confirmsto.call{value:// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;
contract Multisig {
mapping(address => bool) public isOwner;
uint256 public threshold;
struct Tx { address to; uint256 value; bytes data; uint256 confirms; bool done; }
Tx[] public txs;
mapping(uint256 => mapping(address => bool)) public confirmed;
constructor(address[] memory owners, uint256 t) {
for (uint i; i<owners.length; i++) isOwner[owners[i]] = true;
threshold = t;
}
function submit(address to, uint256 value, bytes calldata data) external returns (uint256 id) { /* TODO */ }
function confirm(uint256 id) external { /* TODO */ }
function execute(uint256 id) external { /* TODO */ }
receive() external payable {}
}