Skip to content

Commit 5f2bc8a

Browse files
committed
refactor(cardano-services-client): use CIP129 when querying dreps/:drepId
1 parent a6c65fa commit 5f2bc8a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

packages/cardano-services-client/src/DRepProvider/BlockfrostDRepProvider.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ export class BlockfrostDRepProvider extends BlockfrostProvider implements DRepPr
1111

1212
async getDRepInfo({ id }: GetDRepInfoArgs): Promise<DRepInfo> {
1313
try {
14-
const cip105DRepId = Cardano.DRepID.toCip105DRepID(id); // Blockfrost only supports CIP-105 DRep IDs
15-
const response = await this.request<Responses['drep']>(`governance/dreps/${cip105DRepId.toString()}`);
14+
const cip129DRepId = Cardano.DRepID.toCip129DRepID(id).toString();
15+
const response = await this.request<Responses['drep']>(`governance/dreps/${cip129DRepId}`);
1616
const amount = BigInt(response.amount);
1717
const activeEpoch = response.active_epoch ? Cardano.EpochNo(response.active_epoch) : undefined;
1818
const active = response.active;

0 commit comments

Comments
 (0)