From 26da64184a529ef7ea7571bd0a53ae29793d970f Mon Sep 17 00:00:00 2001 From: Sammy <41593264+stegaBOB@users.noreply.github.com> Date: Wed, 23 Mar 2022 14:05:37 -0400 Subject: [PATCH] feat(web3.js): expose rpcEndpoint in client for web3.js (#23719) Adds a getter to the commitment class to expose the rpcEndpoint property. --- web3.js/src/connection.ts | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/web3.js/src/connection.ts b/web3.js/src/connection.ts index 41842da579..9212203c28 100644 --- a/web3.js/src/connection.ts +++ b/web3.js/src/connection.ts @@ -2230,6 +2230,13 @@ export class Connection { return this._commitment; } + /** + * The RPC endpoint + */ + get rpcEndpoint(): string { + return this._rpcEndpoint; + } + /** * Fetch the balance for the specified public key, return with context */