cartCheck method
Implementation
Future<List<CartProduct>?> cartCheck(List<Map<String, dynamic>> cart) async {
try {
Response response =
await this.client.post("/cart-check", data: {"cart": cart});
return (response.data as List)
.map((e) => CartProduct.fromJson(e))
.toList();
} on Exception catch (e) {
logResponse(e.toString());
}
return null;
}