Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Commit

Permalink
Merge pull request #7605 from LiskHQ/7542-fix_dpos_response
Browse files Browse the repository at this point in the history
Fix DPoS endpoint response - Closes #7542
  • Loading branch information
shuse2 authored Oct 5, 2022
2 parents 3303c8f + 7142e3d commit c930950
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion framework/src/modules/dpos_v2/endpoint.ts
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ export class DPoSEndpoint extends BaseEndpoint {
...delegate,
totalVotesReceived: delegate.totalVotesReceived.toString(),
selfVotes: delegate.selfVotes.toString(),
address: data.key.toString('hex'),
address: cryptoAddress.getLisk32AddressFromAddress(data.key),
};
response.push(delegateJSON);
}
Expand Down
4 changes: 2 additions & 2 deletions framework/test/unit/modules/dpos_v2/endpoint.spec.ts
Original file line number Diff line number Diff line change
Expand Up @@ -165,8 +165,8 @@ describe('DposModuleEndpoint', () => {

describe('getAllDelegates', () => {
describe('when input address is valid', () => {
const address1Str = address1.toString('hex');
const address2Str = address2.toString('hex');
const address1Str = cryptoAddress.getLisk32AddressFromAddress(address1);
const address2Str = cryptoAddress.getLisk32AddressFromAddress(address2);

const addresses = [address1Str, address2Str];

Expand Down

0 comments on commit c930950

Please sign in to comment.