likeUnlike function
- {required int socialFeedId}
Implementation
Future<String> likeUnlike({required int socialFeedId}) async {
appStore.setLoading(true);
Map req = {UserKeys.userId: appStore.userId, UserKeys.socialFeedId: socialFeedId};
try {
var res = CommonModel.fromJson(await (handleResponse(await buildHttpResponse(APIEndPoint.likeUnlike, request: req, method: HttpMethod.POST))));
appStore.setLoading(false);
return res.message.validate();
} catch (e) {
appStore.setLoading(false);
throw errorSomethingWentWrong;
}
}