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

Commit 4e09bfc

Browse files
Merge pull request #965 from github-for-unity/fixes/avoid-nre
Avoid throwing when the first ongui pass is not a layout pass
2 parents 9b356d5 + b9b2751 commit 4e09bfc

File tree

1 file changed

+1
-1
lines changed
  • src/UnityExtension/Assets/Editor/GitHub.Unity/UI

1 file changed

+1
-1
lines changed

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

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ public bool Render(Rect containingRect, Action<GitLock> singleClick = null,
119119
visibleItems[entry.GitLock.ID] = shouldRenderEntry;
120120
}
121121

122-
if (visibleItems[entry.GitLock.ID])
122+
if (visibleItems.ContainsKey(entry.GitLock.ID) && visibleItems[entry.GitLock.ID])
123123
{
124124
entryRect = RenderEntry(entryRect, entry);
125125
}

0 commit comments

Comments
 (0)