Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRichard Darst <rkd@zgib.net>2009-08-31 21:42:28 (GMT)
committer Richard Darst <rkd@zgib.net>2009-08-31 21:42:28 (GMT)
commit2e7ff363fdf6b58ba30176ae814250dbc94be017 (patch)
tree0ce650fa07daf5e99edc445bac72164fe95fe6de
parent09a6f0392311d4ab75d6ad39d1a9099cc6c82ae4 (diff)
Fix double-escaping of #link commands
darcs-hash:20090831214228-82ea9-4d22ec7ccd5621ee9d70f65ba3ad3445fb96abc4.gz
-rw-r--r--items.py8
1 files changed, 4 insertions, 4 deletions
diff --git a/items.py b/items.py
index 63a011e..3c5c5fb 100644
--- a/items.py
+++ b/items.py
@@ -203,12 +203,12 @@ class Link(_BaseItem):
self.url, self.line = (line+' ').split(' ', 1)
# URL-sanitization
self.url_readable = self.url # readable line version
- self.url = self.url.replace('"', "%22")
- # readable line satitization:
- self.line = writers.html(self.line.strip())
+ self.url = self.url
+ self.line = self.line.strip()
def _htmlrepl(self, M):
repl = self.get_replacements(escapewith=writers.html)
- repl['url'] = writers.html(self.url)
+ # special: replace doublequote only for the URL.
+ repl['url'] = writers.html(self.url.replace('"', "%22"))
repl['url_readable'] = writers.html(self.url)
repl['link'] = self.logURL(M)
return repl