From 88b702d5b588a50c3a830eff01fc096a23d44323 Mon Sep 17 00:00:00 2001 From: Danila_Mochalov Date: Mon, 21 Nov 2022 17:06:04 +0400 Subject: [PATCH] =?UTF-8?q?=D0=9F=D0=BE=D1=87=D0=B8=D1=89=D0=B5=D0=BD=20?= =?UTF-8?q?=D0=BA=D0=BE=D0=B4=201?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Locomotive/Locomotive/SetLocomotivesGeneric.cs | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/Locomotive/Locomotive/SetLocomotivesGeneric.cs b/Locomotive/Locomotive/SetLocomotivesGeneric.cs index 2b6612a..104b027 100644 --- a/Locomotive/Locomotive/SetLocomotivesGeneric.cs +++ b/Locomotive/Locomotive/SetLocomotivesGeneric.cs @@ -50,7 +50,7 @@ namespace Locomotive throw new LocomotiveNotFoundException(position); } T result = _places[position]; - _places[position] = null; // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! РАНЬШЕ REMOVE + _places[position] = null; return result; } // Индексатор @@ -72,8 +72,6 @@ namespace Locomotive { foreach (var locomotive in _places) { - // !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! РАНЬШЕ ВОЗВРАЩАЛОСЬ ТОЛЬКО ЕСЛИ НЕ НУЛЛ - yield return locomotive; }