diff --git a/eclipse-language-servers/org.springframework.ide.eclipse.editor.support/src/org/springframework/ide/eclipse/editor/support/yaml/reconcile/YamlSchemaProblems.java b/eclipse-language-servers/org.springframework.ide.eclipse.editor.support/src/org/springframework/ide/eclipse/editor/support/yaml/reconcile/YamlSchemaProblems.java index 9168d46f3..f641f4fcc 100644 --- a/eclipse-language-servers/org.springframework.ide.eclipse.editor.support/src/org/springframework/ide/eclipse/editor/support/yaml/reconcile/YamlSchemaProblems.java +++ b/eclipse-language-servers/org.springframework.ide.eclipse.editor.support/src/org/springframework/ide/eclipse/editor/support/yaml/reconcile/YamlSchemaProblems.java @@ -108,7 +108,7 @@ public class YamlSchemaProblems { } else if (flowStyle instanceof DumperOptions.FlowStyle) { DumperOptions.FlowStyle style = (DumperOptions.FlowStyle) flowStyle; - flow = style.getStyleBoolean(); + flow = style == DumperOptions.FlowStyle.FLOW; } if (!flow) { diff --git a/headless-services/commons/commons-yaml/src/main/java/org/springframework/ide/vscode/commons/yaml/reconcile/YamlSchemaProblems.java b/headless-services/commons/commons-yaml/src/main/java/org/springframework/ide/vscode/commons/yaml/reconcile/YamlSchemaProblems.java index 59c1bfde8..f5bbfcf5f 100644 --- a/headless-services/commons/commons-yaml/src/main/java/org/springframework/ide/vscode/commons/yaml/reconcile/YamlSchemaProblems.java +++ b/headless-services/commons/commons-yaml/src/main/java/org/springframework/ide/vscode/commons/yaml/reconcile/YamlSchemaProblems.java @@ -32,6 +32,7 @@ import org.springframework.ide.vscode.commons.yaml.path.YamlPathSegment; import org.springframework.ide.vscode.commons.yaml.schema.DynamicSchemaContext; import org.springframework.ide.vscode.commons.yaml.schema.YType; import org.springframework.ide.vscode.commons.yaml.schema.YTypedProperty; +import org.yaml.snakeyaml.DumperOptions; import org.yaml.snakeyaml.error.Mark; import org.yaml.snakeyaml.nodes.MappingNode; import org.yaml.snakeyaml.nodes.Node; @@ -113,8 +114,8 @@ public class YamlSchemaProblems { } } } else if (parent instanceof SequenceNode) { - Boolean flowStyle = ((SequenceNode) parent).getFlowStyle().getStyleBoolean(); - if (flowStyle!=null && !flowStyle) { + boolean flowStyle = ((SequenceNode) parent).getFlowStyle() == DumperOptions.FlowStyle.FLOW; + if (!flowStyle) { Mark nodeStart = map.getStartMark(); underline = new DocumentRegion(doc, 0, nodeStart.getIndex()); underline = underline.trimEnd();