From 75cfce96c3a684be38a9489349f3afd17849b6ea Mon Sep 17 00:00:00 2001 From: bl0up Date: Thu, 30 May 2024 16:39:48 +0200 Subject: [PATCH] fix: setting issuer wallet --- subgraph/datasources/diamond.gql.json | 4 ++-- subgraph/datasources/diamond.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/subgraph/datasources/diamond.gql.json b/subgraph/datasources/diamond.gql.json index 4ab7525..e87350c 100755 --- a/subgraph/datasources/diamond.gql.json +++ b/subgraph/datasources/diamond.gql.json @@ -312,7 +312,7 @@ { "name": "interestDen", "type": "BigDecimal!" }, { "name": "withholdingTaxNum", "type": "BigDecimal!" }, { "name": "withholdingTaxDen", "type": "BigDecimal!" }, - { "name": "issuer", "type": "String!" } + { "name": "issuer", "type": "Account!" } ] }, { @@ -347,7 +347,7 @@ { "name": "interestDen", "type": "BigDecimal!" }, { "name": "withholdingTaxNum", "type": "BigDecimal!" }, { "name": "withholdingTaxDen", "type": "BigDecimal!" }, - { "name": "issuer", "type": "String!" } + { "name": "issuer", "type": "Account!" } ] }, { diff --git a/subgraph/datasources/diamond.ts b/subgraph/datasources/diamond.ts index edb8857..2b481e0 100755 --- a/subgraph/datasources/diamond.ts +++ b/subgraph/datasources/diamond.ts @@ -75,7 +75,7 @@ export function handleBondInitializedPart1( ev.withholdingTaxDen = BigDecimal.fromString( event.params.withholdingTaxDen.toString() ); - ev.issuer = Bytes.fromHexString(event.params.issuer); + ev.issuer = event.params.issuer; const bond = fetchBond(contract, event.params.bondId.toString()); bond.coupure = event.params.coupure; bond.withholdingTaxRate = ev.withholdingTaxNum.div(ev.withholdingTaxDen); @@ -165,7 +165,7 @@ export function handleBondParametersEditedPart1( ev.withholdingTaxDen = BigDecimal.fromString( event.params.withholdingTaxDen.toString() ); - ev.issuer = Bytes.fromHexString(event.params.issuer); + ev.issuer = event.params.issuer; const bond = fetchBond(contract, event.params.bondId.toString()); bond.coupure = event.params.coupure; bond.withholdingTaxRate = ev.withholdingTaxNum.div(ev.withholdingTaxDen);