getCurrentUser method

Future<User> getCurrentUser()

Retrieves the current user's profile.

Implementation

Future<User> getCurrentUser() async {
  final url = Uri.https(_baseApiHost, '/v1/me');
  final jsonResponse = await _getJson(url);
  return User.fromJson(jsonResponse);
}