소스 검색

fix(@pythnetwork/pyth-solana-receiver): fixed build

benduran 3 주 전
부모
커밋
89a2fd914e
1개의 변경된 파일3개의 추가작업 그리고 3개의 파일을 삭제
  1. 3 3
      target_chains/solana/sdk/js/pyth_solana_receiver/src/PythSolanaReceiver.ts

+ 3 - 3
target_chains/solana/sdk/js/pyth_solana_receiver/src/PythSolanaReceiver.ts

@@ -465,7 +465,7 @@ export class PythSolanaReceiver {
     this.connection = connection;
     this.wallet = wallet;
     this.provider = new AnchorProvider(this.connection, this.wallet, {
-      commitment: connection.commitment,
+      commitment: connection.commitment!,
     });
     this.receiver = new Program<PythSolanaReceiverProgram>(
       Idl as PythSolanaReceiverProgram,
@@ -669,10 +669,10 @@ export class PythSolanaReceiver {
     );
 
     if (!startUpdateData) {
-      throw new Error('startUpdateData is undefined. this is a bug 🐛');
+      throw new Error("startUpdateData is undefined. this is a bug 🐛");
     }
     if (!endUpdateData) {
-      throw new Error('startUpdateData is undefined. this is a bug 🐛');
+      throw new Error("startUpdateData is undefined. this is a bug 🐛");
     }
 
     // Validate that the start and end updates contain the same number of price feeds