mirror of
https://gitlab.gnome.org/jwestman/blueprint-compiler.git
synced 2025-05-05 16:09:07 -04:00
fix: replace underscore with dash in XML attributes
This commit is contained in:
parent
98bb9e3008
commit
1bd7c37061
1 changed files with 1 additions and 1 deletions
|
@ -33,7 +33,7 @@ class XmlEmitter:
|
||||||
self.result += f"<{tag}"
|
self.result += f"<{tag}"
|
||||||
for key, val in attrs.items():
|
for key, val in attrs.items():
|
||||||
if val is not None:
|
if val is not None:
|
||||||
self.result += f' {key}="{saxutils.escape(str(val))}"'
|
self.result += f' {key.replace("_", "-")}="{saxutils.escape(str(val))}"'
|
||||||
self.result += ">"
|
self.result += ">"
|
||||||
self._tag_stack.append(tag)
|
self._tag_stack.append(tag)
|
||||||
self._needs_newline = False
|
self._needs_newline = False
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue