Skip to content

Commit

Permalink
[CLI] Fix metadata upload with special characters (#430)
Browse files Browse the repository at this point in the history
  • Loading branch information
joaquim-verges committed Dec 1, 2022
1 parent f545a67 commit e684d7e
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
5 changes: 5 additions & 0 deletions .changeset/clean-chefs-film.md
@@ -0,0 +1,5 @@
---
"thirdweb": patch
---

Fix uploading contracts with special characters in the comments
2 changes: 1 addition & 1 deletion packages/cli/src/common/processor.ts
Expand Up @@ -164,7 +164,7 @@ export async function processProject(
const metadataURIs = await Promise.all(
selectedContracts.map(async (c) => {
logger.debug(`Uploading ${c.name}...`);
return await storage.upload(JSON.parse(c.metadata), {
return await storage.upload(JSON.parse(JSON.stringify(c.metadata)), {
uploadWithoutDirectory: true,
});
}),
Expand Down

0 comments on commit e684d7e

Please sign in to comment.