chore: correctly handle empty vault patches
- Lingua principale
- Rust
- Stelle
- 78
- Fork
- 129
- Merge medio
- 4g 14h
- PR unite (30g)
- 52
Descrizione
I think `unwrap_or_default()` turns a remove into a zero word. I don't think we eventually want this, even if for now it will work correctly because the protocol does not generate `Remove`. Let's make it an `expect()` for now and add an issue to address this later
_Originally posted by @igamigo in https://github.com/0xMiden/rust-sdk/pull/2290#discussion_r3583722378_
Guida per i contributori
Apri la guida per i contributori
Direzione di ricerca
Find the code handling vault patches, likely in a file related to transactions or state updates. Look for `unwrap_or_default()` on a patch operation. Change it to an `expect()` with a descriptive message. Run existing tests to ensure the change doesn't break current functionality, as the protocol currently doesn't generate `Remove` operations.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Valutazione
- Stack tecnologico
- rust
- Ambito
- backend
- Tipo di issue
- Bug
- Difficoltà
- 2/5
- Tempo stimato
- 1-3 ore
- Stato di attività
- Tranquilla
- Chiarezza
- Abbastanza chiara
- Idoneità per principianti
- 65/100