bugfix: #16 prevent UI resolves to NRE, during appli teardown with logout-event-being-raised-"too-late".

This commit is contained in:
alexiscatnip
2022-08-06 02:43:06 +08:00
committed by alexiscatnip
parent 8a43a5bc59
commit c3e3b7c7ab
@@ -65,11 +65,17 @@ public class connectivityUI : MonoBehaviour
#region view
private void show_notConnected()
{
this.GetComponent<Image>().color = Color.red;
if (this != null)
{
this.GetComponent<Image>().color = Color.red;
}
}
private void show_isConnected()
{
this.GetComponent<Image>().color = Color.green;
if (this != null)
{
this.GetComponent<Image>().color = Color.green;
}
}
#endregion
}