From d185e5a506226a037ced697d285fd9e939be7d66 Mon Sep 17 00:00:00 2001 From: Fuyao Zhao Date: Wed, 20 Nov 2024 12:27:11 +0800 Subject: [PATCH] chore(runtime): compatible with raw aptos message --- packages/runtime/src/full-service.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/packages/runtime/src/full-service.ts b/packages/runtime/src/full-service.ts index 3861f9422..2697364e9 100644 --- a/packages/runtime/src/full-service.ts +++ b/packages/runtime/src/full-service.ts @@ -134,13 +134,13 @@ export class FullProcessorServiceImpl implements ProcessorServiceImplementation } } break - // case HandlerType.APT_RESOURCE: - // if (dataBinding.data?.aptResource) { - // if (dataBinding.data.aptResource.rawResources && dataBinding.data.aptResource.rawResources.length > 0) { - // dataBinding.data.aptResource.resources = dataBinding.data.aptResource.rawResources.map(e => JSON.parse(e)) - // } - // } - // break + case HandlerType.APT_RESOURCE: + if (dataBinding.data?.aptResource?.resources) { + if (dataBinding.data.aptResource.rawResources && dataBinding.data.aptResource.rawResources.length > 0) { + dataBinding.data.aptResource.resources = dataBinding.data.aptResource.rawResources.map((e) => JSON.parse(e)) + } + } + break case HandlerType.UNKNOWN: if (dataBinding.data?.ethBlock) { if (dataBinding.data.raw.length === 0) {