public async Task <ActionResult <ShoppingCartItem> > AddShoppingCartItem(ShoppingCartItem shoppingCartItem) { try { if (shoppingCartItem == null) { return(BadRequest()); } else { var updatedShoppingCartItem = await _shoppingCartItemRepository.AddShopingCartItem(shoppingCartItem); return(updatedShoppingCartItem); } } catch (Exception) { return(StatusCode(StatusCodes.Status500InternalServerError, "Error with updating data to the database")); } }