@solana/spl-governance
Advanced tools
Comparing version 0.3.6 to 0.3.7
@@ -7,3 +7,3 @@ import { Connection, PublicKey } from '@solana/web3.js'; | ||
export declare function getRealms(connection: Connection, programId: PublicKey): Promise<ProgramAccount<Realm>[]>; | ||
export declare function tryGetRealmConfig(connection: Connection, programId: PublicKey, realmPk: PublicKey): Promise<ProgramAccount<RealmConfigAccount>>; | ||
export declare function tryGetRealmConfig(connection: Connection, programId: PublicKey, realmPk: PublicKey): Promise<ProgramAccount<RealmConfigAccount> | undefined>; | ||
export declare function getRealmConfig(connection: Connection, realmConfigPk: PublicKey): Promise<ProgramAccount<RealmConfigAccount>>; | ||
@@ -10,0 +10,0 @@ export declare function getVoteRecord(connection: Connection, voteRecordPk: PublicKey): Promise<ProgramAccount<VoteRecord>>; |
@@ -32,4 +32,9 @@ "use strict"; | ||
return __awaiter(this, void 0, void 0, function* () { | ||
const realmConfigPk = yield (0, accounts_1.getRealmConfigAddress)(programId, realmPk); | ||
return getGovernanceAccount(connection, realmConfigPk, accounts_1.RealmConfigAccount); | ||
try { | ||
const realmConfigPk = yield (0, accounts_1.getRealmConfigAddress)(programId, realmPk); | ||
return getGovernanceAccount(connection, realmConfigPk, accounts_1.RealmConfigAccount); | ||
} | ||
catch (_a) { | ||
// RealmConfigAccount didn't exist in V1 and was optional in V2 and hence it doesn't have to exist | ||
} | ||
}); | ||
@@ -36,0 +41,0 @@ } |
{ | ||
"name": "@solana/spl-governance", | ||
"version": "0.3.6", | ||
"version": "0.3.7", | ||
"description": "SPL Governance Client API", | ||
@@ -5,0 +5,0 @@ "author": "Solana Maintainers <maintainers@solana.foundation>", |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
486321
6892