chore: update ui service manager of new service

This commit is contained in:
Benjamin Labrecque
2026-07-09 14:04:11 +02:00
parent 901a116955
commit fb4e5d3a35
+1 -8
View File
@@ -1,7 +1,6 @@
import re
import xml.etree.ElementTree as ET
from typing import ClassVar
from xml.dom import minidom
import yaml
from pydantic import BaseModel, ConfigDict, field_validator
@@ -241,13 +240,7 @@ class ServiceManagerUI(BaseModel):
return cainclude_height
def write_to_file(self) -> None:
raw_string = ET.tostring(self.tree.getroot(), encoding="utf-8")
parsed_dom = minidom.parseString(raw_string)
# Write out the file text while natively preserving XML entities
with open(self.config_path, "w", encoding="utf-8") as f:
f.write(parsed_dom.toxml())
self.tree.write(self.config_path, encoding="utf-8", xml_declaration=True)
self.tree.write(self.config_path, encoding="utf-8", xml_declaration=True)
class _ServiceManagerUIMacroElement(BaseModel):