whoIs method Null safety
- String did
Implementation
Future<WhoIs?> whoIs(String did) async {
try {
final response = await httpClient.get<QueryWhoIsResponse>('/registry/who_is/$did', contentType: "application/json");
if (!response.isOk || response.body == null) {
return null;
}
return response.body?.whoIs;
} catch (e) {
Log.warn("Failed to call query using REST API on $baseUrl/$query");
}
return null;
}