Add `last_updated` felt to `get_conversion_rate`
Aperta
standards
- Lingua principale
- Rust
- Stelle
- 132
- Fork
- 167
- Merge medio
- 1g 23h
- PR unite (30g)
- 110
Descrizione
In the price oracle added in #3561, the rate provider decides when its data is too old and returns `has_conversion_rate = 0` for a stale pair. The caller sees only that flag, never when the price was written.
A caller that needs fresher data has no way to enforce it. It either accepts whatever the rate
provider accepts. With `last_updated` it can compare against `tx::get_block_timestamp` and apply its own bound.
Guida per i contributori
Apri la guida per i contributori
Valutazione
Questa issue non è ancora stata valutata.