getWallet method
Looks up an existing wallet and stores the result in controller state.
Returns null when no wallet matches. Listeners fire on state changes.
Implementation
Future<CrossmintWallet?> getWallet(
CrossmintWalletLookupRequest request,
) async {
_state.beginOperation();
try {
final CrossmintWallet? wallet = await client.wallets.getWallet(request);
_state.setWallet(wallet);
return wallet;
} on Exception catch (_) {
_state.setError();
rethrow;
}
}