diff --git a/DoubleDeckerBus/DoubleDeckerBus/SetBusesGeneric.cs b/DoubleDeckerBus/DoubleDeckerBus/SetBusesGeneric.cs index d934c26..a0a4123 100644 --- a/DoubleDeckerBus/DoubleDeckerBus/SetBusesGeneric.cs +++ b/DoubleDeckerBus/DoubleDeckerBus/SetBusesGeneric.cs @@ -29,20 +29,6 @@ namespace DoubleDeckerBus public int Insert(T bus, int position) { - try - { - if (bus.getBus() == null) - { - throw new NullReferenceException(); - } - } - catch (NullReferenceException) { - MessageBox.Show("null"); - } - if (BusyPlaces == _maxCount) { - throw new StorageOverflowException(BusyPlaces); - } - if (position < 0 || position >= _maxCount) { throw new BusNotFoundException("Место указано неверно");