Skip to content

Commit

Permalink
update img dir
Browse files Browse the repository at this point in the history
  • Loading branch information
wnma3mz committed Sep 18, 2020
1 parent 45c6297 commit c499f94
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion wechatarticles/Url2Html.py
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,8 @@ def download_img(self, url):
img = response.content
with open(imgpath, 'wb') as f:
f.write(img)
return imgpath, img
imgpath = os.path.basename(self.img_path)
return os.path.join(imgpath, name), img

def replace_img(self, html):
"""
Expand Down

0 comments on commit c499f94

Please sign in to comment.