jamesread 4 лет назад
Родитель
Сommit
6357c9dc61
1 измененных файлов с 6 добавлено и 0 удалено
  1. 6 0
      internal/config/sanitize.go

+ 6 - 0
internal/config/sanitize.go

@@ -38,6 +38,12 @@ func sanitizeActionArgument(arg *ActionArgument) {
 		arg.Title = arg.Name
 	}
 
+	for idx, choice := range arg.Choices {
+		if choice.Title == "" {
+			arg.Choices[idx].Title = choice.Value
+		}
+	}
+
 	sanitizeActionArgumentNoType(arg)
 
 	// TODO Validate the default against the type checker, but this creates a