Closed NicolaLS closed 1 week ago
(has a one line conflict with #2860)
Also it should be one commit, it's one logical change.
(rebased)
@benma thanks :) I rebased, squashed, and added a comment explaining why we don't return an error when unmarshaling the tx. note fails, PTAL.
Noticed this when planning the refactor of (frontend)
send.tsx
, this PR does not change anything and should be a pure refactor.propose-tx-note
handler did nothing but setting a field onBaseAccount
it did not validate anything, thus removing it and just using the final tx note reduces the code size but changes nothing.We initially separated the note from the txProposal because we did not want to perform any actions when (e.g calculate fee) when user types a note: https://github.com/BitBoxSwiss/bitbox-wallet-app/commit/4eb692c84351dbd23ae391e99ffd5d8452db08f7
It would be good to validate the note though to match the constrains here, but that would not be a refactor so maybe in another PR: https://github.com/BitBoxSwiss/bitbox-wallet-app/blob/87d6219ddb566a52aa410c54cd75d63669e5cec6/backend/accounts/notes/notes.go#L92