Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mrDoctorWho/xmpppy.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJohn Smith <mrdoctorwho@helldev.net>2018-03-16 18:06:25 +0300
committerJohn Smith <mrdoctorwho@helldev.net>2018-03-16 18:06:25 +0300
commitb76d467348c125b11fc1d781fbd95baae437bb58 (patch)
tree2942df076915e8f5354ed04bd14b56e7d4361886
parent503a02c16b02d39ec1aafd9ae54370f918ae3b9a (diff)
Don't strip body after escaping
-rw-r--r--xmpp/simplexml.py6
1 files changed, 4 insertions, 2 deletions
diff --git a/xmpp/simplexml.py b/xmpp/simplexml.py
index ab2a3b4..a7a1d37 100644
--- a/xmpp/simplexml.py
+++ b/xmpp/simplexml.py
@@ -31,12 +31,14 @@ XML_ls = (
("'", "&apos;")
)
+ENCODING = "utf-8"
+
+
def XMLescape(body):
for char, edef in XML_ls:
body = body.replace(char, edef)
- return body.strip()
+ return body
-ENCODING = "utf-8"
def ustr(what):
"""