checkIfUserFollowsUserResponse method

Future<Response> checkIfUserFollowsUserResponse(
  1. String sessionToken,
  2. String userId
)
inherited

Endpoint used: GET /user/follows/user/{id}

Returns a http response of whether the user identified by the current session sessionToken follows a User with userId or uuid and return a http response

Implementation

Future<http.Response> checkIfUserFollowsUserResponse(
    String sessionToken, String userId) async {
  final unencodedPath = '/user/follows/user/$userId';
  final uri = 'https://$AUTHORITY$unencodedPath';
  var response = await http.get(Uri.parse(uri), headers: {
    HttpHeaders.contentTypeHeader: 'application/json',
    HttpHeaders.authorizationHeader: 'Bearer $sessionToken'
  });
  return response;
}