From 85245e4a7f941657c2236e0afacd10bc9cb0b140 Mon Sep 17 00:00:00 2001 From: Gautier Bureau Date: Fri, 16 Dec 2022 13:56:11 +0100 Subject: [PATCH] Fix SlackTerminal optional side attribute. Signed-off-by: Gautier Bureau --- src/iidm/extensions/SlackTerminalXmlSerializer.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/iidm/extensions/SlackTerminalXmlSerializer.cpp b/src/iidm/extensions/SlackTerminalXmlSerializer.cpp index a132f818..47213d63 100644 --- a/src/iidm/extensions/SlackTerminalXmlSerializer.cpp +++ b/src/iidm/extensions/SlackTerminalXmlSerializer.cpp @@ -56,7 +56,7 @@ Extension& SlackTerminalXmlSerializer::read(Extendable& extendable, converter::x } auto& voltageLevel = dynamic_cast(extendable); const std::string& id = context.getAnonymizer().deanonymizeString(context.getReader().getAttributeValue(converter::ID)); - const std::string& side = context.getReader().getAttributeValue(converter::SIDE); + const std::string& side = context.getReader().getOptionalAttributeValue(converter::SIDE, ""); Terminal& terminal = converter::xml::TerminalRefXml::readTerminalRef(voltageLevel.getNetwork(), id, side); extendable.newExtension().withTerminal(terminal).add(); return extendable.getExtension();