From 48406271d0193ee59b04440896cd1870381ecbbe Mon Sep 17 00:00:00 2001 From: ALEXTANG <574809918@qq.com> Date: Tue, 31 May 2022 20:24:19 +0800 Subject: [PATCH] Update Utils.cs --- Assets/TEngine/Runtime/Unitity/Utils.cs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/Assets/TEngine/Runtime/Unitity/Utils.cs b/Assets/TEngine/Runtime/Unitity/Utils.cs index 33b78890..31206b07 100644 --- a/Assets/TEngine/Runtime/Unitity/Utils.cs +++ b/Assets/TEngine/Runtime/Unitity/Utils.cs @@ -143,7 +143,11 @@ namespace TEngine static void LoadAsset(Component component, string path, int index) where T : UnityEngine.Object { - //TODO + if (component == null) + { + TLogger.LogException("component is null"); + return; + } if (string.IsNullOrEmpty(path)) {