Skip to content

Commit

Permalink
chore(tezos): nft royalty fetching fix
Browse files Browse the repository at this point in the history
  • Loading branch information
D4mph1r committed Sep 10, 2024
1 parent 00fce06 commit c113c0e
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/handler/tezos/utils/nftData.ts
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,8 @@ export default async function nftData(
const metaDataInHex = tokenMetaData.token_info.get("");
return bytesToString(metaDataInHex);
};
const tokenMd = await getNftTokenMetaData(contract, BigInt(tokenId));
let tokenMd = await getNftTokenMetaData(contract, BigInt(tokenId));
tokenMd = tokenMd.substring(tokenMd.indexOf("https://"));
let name = "NTEZOS";
try {
provider.addExtension(new Tzip16Module());
Expand All @@ -62,7 +63,7 @@ export default async function nftData(
}
let royalty = 0n;
try {
const metaDataOrURL = await getNftTokenMetaData(contract, BigInt(tokenId));
const metaDataOrURL = tokenMd;
const isUrl = URLCanParse(metaDataOrURL);
let metaData: {
royalties: {
Expand Down

0 comments on commit c113c0e

Please sign in to comment.