getFilter function
Implementation
Future<SaveFilterResponse> getFilter({required FilterType filterType}) async {
String userId = appStore.userId == null ? '' : "user_id=${appStore.userId.toString().validate()}&";
String type = filterType == FilterType.LISTING_FILTER
? 'type=listing'
: filterType == FilterType.EVENT_FILTER
? 'type=event'
: filterType == FilterType.SOCIAL_FRIEND_FILTER
? 'type=social_friend'
: '';
return SaveFilterResponse.fromMap(await (handleResponse(await buildHttpResponse("${APIEndPoint.getFilter}?$userId$type", method: HttpMethod.GET))));
}