haveno-app/lib/haveno_service_clients/account_service_client.dart

21 lines
556 B
Dart
Raw Normal View History

2024-07-14 15:34:24 +00:00
import 'package:haveno_flutter_app/proto/compiled/grpc.pbgrpc.dart';
import 'package:haveno_flutter_app/services/haveno_service.dart';
class AccountServiceClient {
final AccountClient _accountClient;
AccountServiceClient(HavenoService service)
: _accountClient = service.accountClient;
Future<bool> accountExists() async {
try {
final response =
await _accountClient.accountExists(AccountExistsRequest());
return response.accountExists;
} catch (e) {
print('Caught error: $e');
rethrow;
}
}
}