js
js copied to clipboard
metaplex.nfts().findAllByOwner({owner: ownerAdresse})::: error - unhandledRejection
My Code at the my servers endpoint:
const endpoint = process.env.SOLANA_RPC_HOST; const connection = new Connection(endpoint, { commitment: "confirmed", disableRetryOnRateLimit: true }); const metaplex = new Metaplex(connection); const ownerAdresse = new PublicKey(pubKey); const allNfts = await metaplex.nfts().findAllByOwner({owner: ownerAdresse});
The error I get, it actually worked for a while, then recently it started to throw this error:
error - unhandledRejection: StructError: Expected the value to satisfy a union of
type | type, but received: [object Object] at validate (C:\Users\Flori\Desktop\Poker Game Development\Pokergame Entwicklung\Neueste Version 2023\node_modules\superstruct\lib\index.cjs:363:19) at Object.create (C:\Users\Flori\Desktop\Poker Game Development\Pokergame Entwicklung\Neueste Version 2023\node_modules\superstruct\lib\index.cjs:319:18) at Connection.getProgramAccounts (C:\Users\Flori\Desktop\Poker Game Development\Pokergame Entwicklung\Neueste Version 2023\node_modules\@solana\web3.js\lib\index.cjs.js:7834:29) id: null }, type: 'union', refinement: undefined, key: undefined, path: [], branch: [ { jsonrpc: '2.0', error: [Object], id: null } ], failures: [Function (anonymous)]