Invalid metadata address
Closed this issue · 2 comments
nitruoc commented
Hello!
I'm trying to retrieve metadata from an NFT using the code sample in #22. It's working pretty well but for some NFTs the metadata address retrieve by findProgramAddress is'nt the good one.
Example :
Mint: 887sH18E7pkUco4zfUFZxiXAEsgCVRd6vNX5HaT9CSmC
Expected metadata address: 8HXWP5BQ83riaGdYofKqcKLkbgeusy6efNc4E6ZDHj6s
Metadata generated: 7C8w6HC1bMqDMV6nC9Krmz7qV1eTutmsprb57F1nx6Xd
$metaplex = new PublicKey(MetaplexProgram::METAPLEX_PROGRAM_ID);
list($pda, $bump) = PublicKey::findProgramAddress(['metadata', $metaplex, (new PublicKey($mint))], $metaplex);
$address = $pda->getPublicKey()->toBase58();
neverything commented
Hey I've been using a workaround in my job classes, see #12 (comment)
nitruoc commented
It's working! Thanks for your help!