@dynamic-labs/sdk-react-core
Version:
A React SDK for implementing wallet web3 authentication and authorization to your website.
16 lines (12 loc) • 564 B
JavaScript
'use client'
;
Object.defineProperty(exports, '__esModule', { value: true });
// verifies if user has any type of wallet by checking if walletProvider is present
// as walletProvider is only present in VC wallets
const getUserWalletsFromVerifiedCredentials = (user) => {
var _a;
return (_a = user.verifiedCredentials) === null || _a === void 0 ? void 0 : _a.filter(
// Only wallets has walletProviders
({ walletProvider }) => walletProvider);
};
exports.getUserWalletsFromVerifiedCredentials = getUserWalletsFromVerifiedCredentials;