Skip to content

Commit

Permalink
Respond to feedback. Remove nullable disable.
Browse files Browse the repository at this point in the history
  • Loading branch information
JeremyKuhne committed Nov 3, 2021
1 parent 73bfe7e commit ae58704
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@
// The .NET Foundation licenses this file to you under the MIT license.
// See the LICENSE file in the project root for more information.

#nullable disable

using System.ComponentModel;
using System.Windows.Forms.Design;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1653,8 +1653,9 @@ private PropertyTab CreateTab(Type tabType, IDesignerHost host)
{
tab = CreatePropertyTab(tabType);
}
catch (Exception)
catch (Exception exception)
{
Debug.Fail($"{nameof(CreatePropertyTab)} failed. {exception.Message}");
return null;
}

Expand Down Expand Up @@ -1689,14 +1690,13 @@ private PropertyTab CreateTab(Type tabType, IDesignerHost host)
tab = (PropertyTab)Activator.CreateInstance(tabType);
}
}
catch
catch (Exception exception)
{
Debug.Fail($"Failed to create {nameof(PropertyTab)}. {exception.Message}");
tab = null;
}
}

Debug.Assert(tab is not null, "Failed to create tab!");

if (tab is not null)
{
if (tab.Bitmap is null)
Expand Down

0 comments on commit ae58704

Please sign in to comment.