Skip to content

Commit

Permalink
feat: support minContextSlot in getParsedAccountInfo method (solana-l…
Browse files Browse the repository at this point in the history
  • Loading branch information
jstarry authored and xiangzhu70 committed Aug 17, 2022
1 parent 1f256c3 commit 4cc8801
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion web3.js/src/connection.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2871,14 +2871,17 @@ export class Connection {
*/
async getParsedAccountInfo(
publicKey: PublicKey,
commitment?: Commitment,
commitmentOrConfig?: Commitment | GetAccountInfoConfig,
): Promise<
RpcResponseAndContext<AccountInfo<Buffer | ParsedAccountData> | null>
> {
const {commitment, config} =
extractCommitmentFromConfig(commitmentOrConfig);
const args = this._buildArgs(
[publicKey.toBase58()],
commitment,
'jsonParsed',
config,
);
const unsafeRes = await this._rpcRequest('getAccountInfo', args);
const res = create(
Expand Down

0 comments on commit 4cc8801

Please sign in to comment.