Skip to content

Commit

Permalink
feat: get local working for 3.12 and fix some code quality issue
Browse files Browse the repository at this point in the history
  • Loading branch information
Vinit Kumar committed Oct 5, 2023
1 parent 0ffb007 commit 00d09f2
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions json2xml/dicttoxml.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
import datetime
import logging
import numbers
import os
from collections.abc import Callable, Sequence
from random import SystemRandom
from typing import Any, Dict, Union
Expand Down Expand Up @@ -270,7 +269,7 @@ def dict2xml_str(
val_attr: dict[str, str] = item.pop("@attrs", attr) # update attr with custom @attr if exists
rawitem = item["@val"] if "@val" in item else item
if is_primitive_type(rawitem):
if isinstance(rawitem , str):
if isinstance(rawitem, str):
subtree = escape_xml(rawitem)
else:
subtree = rawitem
Expand Down Expand Up @@ -702,4 +701,3 @@ def dicttoxml(
)

return "".join(output).encode("utf-8")

0 comments on commit 00d09f2

Please sign in to comment.