Skip to content

Commit

Permalink
Stupid mistake.
Browse files Browse the repository at this point in the history
  • Loading branch information
felixfontein committed Oct 23, 2016
1 parent a1eb111 commit 9fbb5bf
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion nikola/nikola.py
Expand Up @@ -1355,7 +1355,7 @@ def rewrite_links(self, doc, src, lang, url_type=None, is_fragment=False):
doc.rewrite_links(lambda dst: self.url_replacer(src, dst, lang, url_type), resolve_base_href=False)

# lxml ignores srcset in img and source elements, so do that by hand
objs = list(doc.xpath('({}//img|{}//source)'.format('' if is_fragment else '*')))
objs = list(doc.xpath('({0}//img|{0}//source)'.format('' if is_fragment else '*')))
for obj in objs:
if 'srcset' in obj.attrib:
urls = [u.strip() for u in obj.attrib['srcset'].split(',')]
Expand Down

0 comments on commit 9fbb5bf

Please sign in to comment.