verify method

  1. @override
bool verify()
override

Implementation

@override
bool verify() {
  // Verify all inputs have been signed
  for (int i = 0; i < txData.psbt.inputs.length; i++) {
    final input = txData.psbt.inputs[i];

    if (txData.isTaproot) {
      // Check if Taproot signature exists
      if (input.taprootKeySpendSignature == null) {
        return false;
      }
    } else {
      // Check if Legacy signature exists
      if (input.partialSigs == null || input.partialSigs!.isEmpty) {
        return false;
      }
    }
  }
  return true;
}