Skip to content

Commit

Permalink
fix event history dto to blockNumber
Browse files Browse the repository at this point in the history
  • Loading branch information
cauta committed Jun 3, 2024
1 parent c706497 commit 72def51
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ export class MonitorEventHistoryResponseDto {
hash: string;

@ApiResponseProperty()
blockNum: number; // decimal string
blockNumber: number; // decimal string

@ApiResponseProperty()
contract: {
Expand Down Expand Up @@ -128,7 +128,7 @@ export class MonitorEventHistoryResponseDto {
.monitorId(dto.monitorId)
.associatedAddress(dto.associatedAddress)
.hash(dto.hash)
.blockNum(dto.blockNum)
.blockNumber(dto.blockNumber)
.contract(dto.contract)
.fromAddress(dto.fromAddress)
.toAddress(dto.toAddress)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ export class EventHistory {
hash: string;

@Prop()
blockNum: number; // decimal string
blockNumber: number; // decimal string

@Prop({ type: Object })
contract: {
Expand Down Expand Up @@ -96,7 +96,7 @@ export class EventHistory {
monitorId: this.monitorId,
associatedAddress: this.associatedAddress,
hash: this.hash,
blockNum: this.blockNum,
blockNumber: this.blockNumber,
contract: this.contract,
fromAddress: this.fromAddress,
toAddress: this.toAddress,
Expand Down Expand Up @@ -124,7 +124,7 @@ export class EventHistory {
instance.chain = chain;
instance.monitorId = monitorId;
instance.hash = log.transactionHash;
instance.blockNum = log.blockNumber;
instance.blockNumber = log.blockNumber;
instance.contract = {
address: ethers.getAddress(log.address).toLowerCase(),
name: null,
Expand Down Expand Up @@ -171,7 +171,7 @@ export class EventHistory {
instance.chain = chain;
instance.monitorId = monitorId;
instance.hash = log.transactionHash;
instance.blockNum = log.blockNumber;
instance.blockNumber = log.blockNumber;
instance.contract = {
address: ethers.getAddress(log.address).toLowerCase(),
name: null,
Expand Down Expand Up @@ -217,7 +217,7 @@ export class EventHistory {
instance.chain = chain;
instance.monitorId = monitorId;
instance.hash = transaction.hash;
instance.blockNum = transaction.blockNumber;
instance.blockNumber = transaction.blockNumber;
instance.fromAddress = transaction.from.toLowerCase();
instance.toAddress = transaction.to.toLowerCase();

Expand Down

0 comments on commit 72def51

Please sign in to comment.