Skip to content

Commit

Permalink
support string (#1447)
Browse files Browse the repository at this point in the history
  • Loading branch information
jayantk authored Apr 11, 2024
1 parent c727195 commit 443f145
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@pythnetwork/pyth-solana-receiver",
"version": "0.5.0",
"version": "0.6.0",
"description": "Pyth solana receiver SDK",
"homepage": "https://pyth.network",
"main": "lib/index.js",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -709,12 +709,12 @@ export class PythSolanaReceiver {
/**
* Fetch the contents of a price feed account
* @param shardId The shard ID of the set of price feed accounts. This shard ID allows for multiple price feed accounts for the same price feed id to exist.
* @param priceFeedId The price feed ID.
* @param priceFeedId The price feed ID, as either a 32-byte buffer or hexadecimal string with or without a leading "0x" prefix.
* @returns The contents of the deserialized price feed account or `null` if the account doesn't exist
*/
async fetchPriceFeedAccount(
shardId: number,
priceFeedId: Buffer
priceFeedId: Buffer | string
): Promise<PriceUpdateAccount | null> {
return this.receiver.account.priceUpdateV2.fetchNullable(
this.getPriceFeedAccountAddress(shardId, priceFeedId)
Expand All @@ -724,7 +724,7 @@ export class PythSolanaReceiver {
/**
* Derive the address of a price feed account
* @param shardId The shard ID of the set of price feed accounts. This shard ID allows for multiple price feed accounts for the same price feed id to exist.
* @param priceFeedId The price feed ID.
* @param priceFeedId The price feed ID, as either a 32-byte buffer or hexadecimal string with or without a leading "0x" prefix.
* @returns The address of the price feed account
*/
getPriceFeedAccountAddress(
Expand All @@ -742,7 +742,7 @@ export class PythSolanaReceiver {
/**
* Derive the address of a price feed account
* @param shardId The shard ID of the set of price feed accounts. This shard ID allows for multiple price feed accounts for the same price feed id to exist.
* @param priceFeedId The price feed ID.
* @param priceFeedId The price feed ID, as either a 32-byte buffer or hexadecimal string with or without a leading "0x" prefix.
* @param pushOracleProgramId The program ID of the Pyth Push Oracle program. If not provided, the default deployment will be used.
* @returns The address of the price feed account
*/
Expand Down

0 comments on commit 443f145

Please sign in to comment.