Skip to content

Commit

Permalink
Fixing possible null ref exception
Browse files Browse the repository at this point in the history
  • Loading branch information
batzen committed Mar 25, 2020
1 parent d5969e6 commit c535f5e
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,8 @@ private RibbonGroupHeaderAutomationPeer HeaderPeer
this.headerPeer = new RibbonGroupHeaderAutomationPeer(this.OwningGroup.CollapsedHeaderContentControl);
}
}
else if (this.OwningGroup.Header != null)
else if (this.OwningGroup.Header != null
&& this.OwningGroup.HeaderContentControl != null)
{
this.headerPeer = new RibbonGroupHeaderAutomationPeer(this.OwningGroup.HeaderContentControl);
}
Expand Down

0 comments on commit c535f5e

Please sign in to comment.