magic-js
magic-js copied to clipboard
MagicWallet type is different from the data type being returned
✅ Prerequisites
- [x] Did you perform a cursory search of open issues? Is this bug already reported elsewhere?
- [x] Are you running the latest SDK version?
- [x] Are you reporting to the correct repository (
magic-sdk
)?
🐛 Description
[Description of the bug.]
🧩 Steps to Reproduce
- Run this code
const userMetadata = await magic.users.getMetadataByTokenAndWallet(didToken, WalletType.SOLANA);
🤔 Expected behavior
Expectation is that userMetadata.wallets is of this
export interface MagicWallet {
network: string | null;
publicAddress: string | null;
walletType: string | null;
}
😮 Actual behavior
What you get in the response is this
wallet: {
network: 'MAINNET',
public_address: 'hCRR31qArEDTwUpaMP6Y2SndhUUJ4dncd1pvSmyUzi9',
wallet_type: 'SOLANA'
}
Seems like the response is in snake case instead of camel case
@akinwol Could you also provide the magic-sdk version along with the Solana extension version?
@ayv8er see the versions below
"@magic-ext/solana": "^13.1.3", "@magic-sdk/admin": "^1.10.0",
@akinwol Could I also ask for magic-sdk version as well?
@ayv8er "magic-sdk": "^17.1.4",