Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Browse the repository at this point in the history
The payjoin psbt construction code reintroduces original psbt inputs that the receiver may have lost. It does this by iterating through each proposed input and original input. This fix only iterates to the next original_input once a proposed input that matches is found, otherwise inputs could be skipped and signing could fail. The outer loop already iterates through proposed inputs. Inputs in the proposal are in the same order as the original as per spec, and just insert receiver inputs so this iteration will always find matches.
- Loading branch information