Skip to content
This repository was archived by the owner on Dec 5, 2024. It is now read-only.

Commit 3e7861a

Browse files
This can be called when the tree objects are null
1 parent 9332fba commit 3e7861a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/UnityExtension/Assets/Editor/GitHub.Unity/UI/BranchesView.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -185,14 +185,14 @@ private void UpdateTreeIcons()
185185

186186
private void UpdateTreeStyles()
187187
{
188-
if (treeLocals.FolderStyle == null)
188+
if (treeLocals != null && treeLocals.FolderStyle == null)
189189
{
190190
treeLocals.FolderStyle = Styles.Foldout;
191191
treeLocals.TreeNodeStyle = Styles.TreeNode;
192192
treeLocals.ActiveTreeNodeStyle = Styles.TreeNodeActive;
193193
}
194194

195-
if (treeRemotes.FolderStyle == null)
195+
if (treeRemotes != null && treeRemotes.FolderStyle == null)
196196
{
197197
treeRemotes.FolderStyle = Styles.Foldout;
198198
treeRemotes.TreeNodeStyle = Styles.TreeNode;

0 commit comments

Comments
 (0)