Skip to content

Commit

Permalink
Add rpc url override (pyth-network#1234)
Browse files Browse the repository at this point in the history
  • Loading branch information
guibescos authored Jan 23, 2024
1 parent c5d02af commit 4abbbd1
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -41,10 +41,11 @@ const COMMITMENT: Commitment =
(process.env.COMMITMENT as Commitment) ?? "confirmed";

const GUARDIAN_RPC = process.env.GUARDIAN_RPC;
const SOLANA_RPC_URL = process.env.SOLANA_RPC_URL;

async function run() {
const provider = new AnchorProvider(
new Connection(getPythClusterApiUrl(CLUSTER), COMMITMENT),
new Connection(SOLANA_RPC_URL ?? getPythClusterApiUrl(CLUSTER), COMMITMENT),
new NodeWallet(KEYPAIR),
{
commitment: COMMITMENT,
Expand Down

0 comments on commit 4abbbd1

Please sign in to comment.