diff --git a/IceCreamShop/IceCreamShopFileImplement/Implements/OrderStorage.cs b/IceCreamShop/IceCreamShopFileImplement/Implements/OrderStorage.cs index 64a4b19..983f9d1 100644 --- a/IceCreamShop/IceCreamShopFileImplement/Implements/OrderStorage.cs +++ b/IceCreamShop/IceCreamShopFileImplement/Implements/OrderStorage.cs @@ -88,6 +88,8 @@ model) public OrderViewModel AccessIceCreamStorage(OrderViewModel model) { + if (model == null) + return null; foreach (var iceCream in source.IceCreams) { if (iceCream.Id == model.IceCreamId)