The Simple Signer Algorithm is not updated to the fact that SegWitv0 inputs are now typically expected to have both the non-witness-utxo and the witness-utxo field (instead of the ealier requirement of omitting the non-witness-utxo).
By reverting the order of the checks, it is at least semantically correct.
Possible TODOs for followups:
- Update for segwitv1 signing
- Recommend checking the non-witness-utxo for segwitv0 inputs.