Skip to content

Commit

Permalink
fix: modify upload to pinata function call to new one
Browse files Browse the repository at this point in the history
  • Loading branch information
clauBv23 committed Feb 12, 2025
1 parent cccd6af commit cc0d964
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -81,11 +81,16 @@ const func: DeployFunction = async function (hre: HardhatRuntimeEnvironment) {

let metadataCIDPath = '0x';

if (!process.env.PUB_PINATA_JWT) {
throw new Error('PUB_PINATA_JWT is not set');
}

if (!isLocal(hre.network)) {
// Upload the metadata to IPFS
metadataCIDPath = await uploadToPinata(
JSON.stringify(MANAGEMENT_DAO_METADATA, null, 2),
`management-dao-metadata`
MANAGEMENT_DAO_METADATA,
`management-dao-metadata`,
process.env.PUB_PINATA_JWT
);
}

Expand Down

0 comments on commit cc0d964

Please sign in to comment.