Hello, I am trying to save/upload a png to IPFS using saveIPFS method, but now I am getting the error āError: Cannot set property āhashā of undefinedā
This is how i am calling the methods. The error seems to throw inside the saveIPFS method. Any idea what it could be? I followed the docs/tutorial pretty much exactly. (buffer is the base64 png string)
Maybe Im not supposed to use 'useMasterKey", but if I donāt put that in I get the āError: File upload by public is disabled.ā error.
const file = new Moralis.File('filename.png',{base64 : buffer});
await nftFile.saveIPFS({ useMasterKey: true });
const nftFilePath = nftFile.ipfs();
const nftFileHash = nftFile.hash();