We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 50c23e1 commit bdfbfd2Copy full SHA for bdfbfd2
1 file changed
Runtime/UIForm.cs
@@ -298,13 +298,7 @@ public virtual void OnClose(bool isShutdown, object userData)
298
gameObject.SetLayerRecursively(m_OriginalLayer);
299
m_Available = false;
300
Visible = false;
301
- if (m_EventSubscriber != null)
302
- {
303
- m_EventSubscriber.UnSubscribeAll();
304
- ReferencePool.Release(m_EventSubscriber);
305
- }
306
-
307
- m_EventSubscriber = null;
+ m_EventSubscriber?.UnSubscribeAll();
308
}
309
310
/// <summary>
0 commit comments