MatrixSynapse/synapse/rest/media/v1
Patrick Cloke ba7a91aea5
Refactor oEmbed previews (#10814)
The major change is moving the decision of whether to use oEmbed
further up the call-stack. This reverts the _download_url method to
being a "dumb" functionwhich takes a single URL and downloads it
(as it was before #7920).

This also makes more minor refactorings:

* Renames internal variables for clarity.
* Factors out shared code between the HTML and rich oEmbed
  previews.
* Fixes tests to preview an oEmbed image.
2021-09-21 16:09:57 +00:00
..
__init__.py [pyupgrade] `synapse/` (#10348) 2021-07-19 15:28:05 +01:00
_base.py Add missing type hints to non-client REST servlets. (#10817) 2021-09-15 08:45:32 -04:00
config_resource.py
download_resource.py Mitigate media repo XSSs on IE11. (#10468) 2021-07-27 13:45:10 +02:00
filepath.py Add missing type hints to non-client REST servlets. (#10817) 2021-09-15 08:45:32 -04:00
media_repository.py Add missing type hints to non-client REST servlets. (#10817) 2021-09-15 08:45:32 -04:00
media_storage.py Add missing type hints to non-client REST servlets. (#10817) 2021-09-15 08:45:32 -04:00
oembed.py Refactor oEmbed previews (#10814) 2021-09-21 16:09:57 +00:00
preview_url_resource.py Refactor oEmbed previews (#10814) 2021-09-21 16:09:57 +00:00
storage_provider.py Add missing type hints to non-client REST servlets. (#10817) 2021-09-15 08:45:32 -04:00
thumbnail_resource.py Convert media repo's FileInfo to attrs. (#10785) 2021-09-14 07:09:38 -04:00
thumbnailer.py Add missing type hints to non-client REST servlets. (#10817) 2021-09-15 08:45:32 -04:00
upload_resource.py