From 771c7776c057f8e3eac1cadb8309fbdea1d06a2f Mon Sep 17 00:00:00 2001 From: Simon Jackson Date: Sat, 23 Apr 2022 11:45:32 +0100 Subject: [PATCH] Taking in fix from https://bitbucket.org/UnityUIExtensions/unity-ui-extensions/pull-requests/132 --- Runtime/Scripts/Primitives/UILineRenderer.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Runtime/Scripts/Primitives/UILineRenderer.cs b/Runtime/Scripts/Primitives/UILineRenderer.cs index 590bdba..6f2f093 100644 --- a/Runtime/Scripts/Primitives/UILineRenderer.cs +++ b/Runtime/Scripts/Primitives/UILineRenderer.cs @@ -466,7 +466,7 @@ namespace UnityEngine.UI.Extensions protected override void OnEnable() { base.OnEnable(); - if (m_points?.Length == 0) + if (m_points == null || m_points?.Length == 0) { m_points = new Vector2[1]; }