Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix(wallet): correct change checks in transaction builder #5235

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -488,9 +488,7 @@ impl SenderTransactionInitializer {
Self::check_value("Missing Lock Height", &self.lock_height, &mut message);
Self::check_value("Missing Fee per gram", &self.fee_per_gram, &mut message);
Self::check_value("Missing Offset", &self.offset, &mut message);
Self::check_value("Change script", &self.private_nonce, &mut message);
Self::check_value("Change input data", &self.private_nonce, &mut message);
Self::check_value("Change script private key", &self.private_nonce, &mut message);
Self::check_value("Missing private nonce", &self.private_nonce, &mut message);

if !message.is_empty() {
return self.build_err(&message.join(","));
Expand Down Expand Up @@ -731,8 +729,7 @@ mod test {
// We should have a bunch of fields missing still, but we can recover and continue
assert_eq!(
err.message,
"Missing Lock Height,Missing Fee per gram,Missing Offset,Change script,Change input data,Change script \
private key"
"Missing Lock Height,Missing Fee per gram,Missing Offset,Missing private nonce"
);

let mut builder = err.builder;
Expand Down