From 4f64f2b9a1be0bd042f1317ecaaee2ab9a0955ab Mon Sep 17 00:00:00 2001 From: Raman Shekhawat Date: Tue, 3 Sep 2024 13:01:06 +0530 Subject: [PATCH] add operator to approved & unnaproved sns message --- src/mappings/multiTokens/events/approved.ts | 4 +++- src/mappings/multiTokens/events/unapproved.ts | 2 ++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/mappings/multiTokens/events/approved.ts b/src/mappings/multiTokens/events/approved.ts index e198f565..fa18a42c 100644 --- a/src/mappings/multiTokens/events/approved.ts +++ b/src/mappings/multiTokens/events/approved.ts @@ -102,8 +102,10 @@ export async function approved( id: item.id, name: item.name, body: { - collectionId: data.collectionId.toString(), + kind: data.tokenId !== undefined ? 'token' : 'collection', address, + operator: data.operator, + collectionId: data.collectionId.toString(), tokenId: data.tokenId ? `${data.collectionId}-${data.tokenId}` : null, extrinsic: item.extrinsic.id, }, diff --git a/src/mappings/multiTokens/events/unapproved.ts b/src/mappings/multiTokens/events/unapproved.ts index 88826074..d7ce8228 100644 --- a/src/mappings/multiTokens/events/unapproved.ts +++ b/src/mappings/multiTokens/events/unapproved.ts @@ -76,7 +76,9 @@ export async function unapproved( id: item.id, name: item.name, body: { + kind: data.tokenId !== undefined ? 'token' : 'collection', address, + operator: data.operator, collectionId: data.collectionId.toString(), tokenId: data.tokenId ? `${data.collectionId}-${data.tokenId}` : null, extrinsic: item.extrinsic.id,