zulip/zerver/lib/url_preview
Alex Vandiver ad8943a64a url_preview: Only extract img tags with an `src`.
Some `<img>` tags do not have an SRC, if they are rewritten using JS
to have one later.  Attempting to access `first_image['src']` on these
will raise an exception, as they have no such attribute.

Only look for images which have a defined `src` attribute on them.  We
could instead check if `first_image.has_attr('src')`, but this seems
only likely to produce fewer valid images.
2020-08-18 14:26:21 -04:00
..
parsers url_preview: Only extract img tags with an `src`. 2020-08-18 14:26:21 -04:00
__init__.py
oembed.py python: Fix misuse of Optional types for optional parameters. 2020-06-13 15:31:27 -07:00
preview.py python: Fix misuse of Optional types for optional parameters. 2020-06-13 15:31:27 -07:00