Skip to content

Commit

Permalink
fix: api
Browse files Browse the repository at this point in the history
  • Loading branch information
remiroyc committed Nov 18, 2024
1 parent e82d7e3 commit 2f97f02
Showing 1 changed file with 9 additions and 14 deletions.
23 changes: 9 additions & 14 deletions apps/web/src/server/api/routers/bridgeRequest.ts
Original file line number Diff line number Diff line change
Expand Up @@ -134,20 +134,15 @@ export const bridgeRequestRouter = createTRPCRouter({
token_id: bridgeRequest.token_ids[0],
}))
);
requestMetadataByReqHash = requestMetadatas.result.reduce(
(acc, current) => {
return {
...acc,
[`${current.token_id}`]: {
contractName: current.contract_name,
media: getMediaObjectFromUrl(
current.metadata?.normalized.image
),
},
};
},
{}
);
requestMetadataByReqHash = requestMetadatas.reduce((acc, current) => {
return {
...acc,
[`${current.token_id}`]: {
contractName: current.collection_name,
media: getMediaObjectFromUrl(current.metadata?.image),
},
};
}, {});
}

const bridgeRequestsWithMetadata = bridgeRequests.map(
Expand Down

0 comments on commit 2f97f02

Please sign in to comment.