fix: NPE in menu installer editor

This commit is contained in:
bd_ 2023-01-02 16:41:27 +09:00
parent 569275dcba
commit 435ce7b248

View File

@ -282,9 +282,13 @@ namespace nadena.dev.modular_avatar.core.editor
if (result != ValidateExpressionMenuIconResult.Success) return result; if (result != ValidateExpressionMenuIconResult.Success) return result;
// Labels // Labels
foreach (VRCExpressionsMenu.Control.Label label in control.labels) { if (control.labels != null)
ValidateExpressionMenuIconResult labelResult = Util.ValidateExpressionMenuIcon(label.icon); {
if (labelResult != ValidateExpressionMenuIconResult.Success) return labelResult; foreach (VRCExpressionsMenu.Control.Label label in control.labels)
{
ValidateExpressionMenuIconResult labelResult = Util.ValidateExpressionMenuIcon(label.icon);
if (labelResult != ValidateExpressionMenuIconResult.Success) return labelResult;
}
} }
// SubMenu // SubMenu