aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGertjan van den Burg <gertjanvandenburg@gmail.com>2020-04-28 13:15:54 +0100
committerGertjan van den Burg <gertjanvandenburg@gmail.com>2020-04-28 13:15:54 +0100
commit2667c488ac02d4a346bc3b89ff11b7f27125acc0 (patch)
tree573d35dd077501fe34c34f357bdf0a3d4aecd9fd
parentMerge branch 'master' into bugfix/html-images (diff)
downloadpaper2remarkable-2667c488ac02d4a346bc3b89ff11b7f27125acc0.tar.gz
paper2remarkable-2667c488ac02d4a346bc3b89ff11b7f27125acc0.zip
Strip trailing slash from image urls
-rw-r--r--paper2remarkable/providers/html.py1
1 files changed, 1 insertions, 0 deletions
diff --git a/paper2remarkable/providers/html.py b/paper2remarkable/providers/html.py
index 9f8394c..d71f210 100644
--- a/paper2remarkable/providers/html.py
+++ b/paper2remarkable/providers/html.py
@@ -67,6 +67,7 @@ class ImgProcessor(markdown.treeprocessors.Treeprocessor):
img.attrib["src"] = urllib.parse.urljoin(
self._base_url, img.attrib["src"]
)
+ img.attrib["src"] = img.attrib['src'].rstrip('/')
class HTMLInformer(Informer):