From 58e4cce66962992c2c9d50f87d50c1b799ce2de1 Mon Sep 17 00:00:00 2001 From: AnnZhimol Date: Tue, 29 Nov 2022 19:40:13 +0400 Subject: [PATCH] =?UTF-8?q?=D0=B8=D0=B7=D0=BC=D0=B5=D0=BD=D0=B5=D0=BD?= =?UTF-8?q?=D0=B8=D1=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Warship/Warship/SetWarshipsGeneric.cs | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/Warship/Warship/SetWarshipsGeneric.cs b/Warship/Warship/SetWarshipsGeneric.cs index 1b66385..401a6b8 100644 --- a/Warship/Warship/SetWarshipsGeneric.cs +++ b/Warship/Warship/SetWarshipsGeneric.cs @@ -23,12 +23,7 @@ namespace Warship public int Insert(T warship) { - if (Count >= _maxCount) - throw new StorageOverflowException(_maxCount); - - _places.Insert(0, warship); - - return 0; + return Insert(warship, 0); } public int Insert(T warship, int position)