Skip to content

Commit 404c21a

Browse files
Apply suggestions from code review
Co-authored-by: guibescos <[email protected]>
1 parent 4699780 commit 404c21a

File tree

1 file changed

+2
-2
lines changed
  • target_chains/solana/sdk/js/pyth_solana_receiver

1 file changed

+2
-2
lines changed

target_chains/solana/sdk/js/pyth_solana_receiver/README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,9 +177,9 @@ This method does sacrifice some security however -- please see the method docume
177177

178178
### Post a TWAP price update
179179

180-
TWAP prices updates are calculated using a pair of verifiable cumulative price updates per price feed (the "start" and "end" updates for the given time window), and then performing an averaging calculation on-chain to create the time-weighted average price.
180+
TWAP price updates are calculated using a pair of verifiable cumulative price updates per price feed (the "start" and "end" updates for the given time window), and then performing an averaging calculation on-chain to create the time-weighted average price.
181181

182-
The flow of using, verifying, posting, and consuming these prices are the same as standard price updates. Get the binary update data from Hermes or Benchmarks, post and verify the VAAs via the Wormhole contract, and verify the updates against the VAAs via Pyth receiver contract. After this, you can consume the calculated TWAP posted to the TwapUpdate account. You can also optionally close these ephemeral accounts after the TWAP has been consumed to save on rent.
182+
The flow of using, verifying, posting, and consuming these prices is the same as standard price updates. Get the binary update data from Hermes or Benchmarks, post and verify the VAAs via the Wormhole contract, and verify the updates against the VAAs via Pyth receiver contract. After this, you can consume the calculated TWAP posted to the TwapUpdate account. You can also optionally close these ephemeral accounts after the TWAP has been consumed to save on rent.
183183

184184
```typescript
185185
// Fetch the binary TWAP data from hermes or benchmarks. See Preliminaries section above for more info.

0 commit comments

Comments
 (0)