find image regexp

This commit is contained in:
a.gorbunov 2020-01-20 11:04:02 +00:00
parent a31763c550
commit c0b517e5fe

View File

@ -207,7 +207,7 @@ def section_name_into_index_name(section_name: str):
def get_url_images_in_text(text):
"""Find images urls in text"""
return re.findall(r'\<img.+src=(?!https?:\/\/)([^\/].+?)[\"|\']>', text)
return re.findall(r'\<img.+src="([^"]+)".+>', text)
def get_image_meta_by_url(url) -> (int, int, int):