summary refs log tree commit diff
path: root/synapse/rest/media/v1/thumbnail_resource.py
diff options
context:
space:
mode:
authorErik Johnston <erikj@jki.re>2018-02-05 11:28:52 +0000
committerGitHub <noreply@github.com>2018-02-05 11:28:52 +0000
commit1f881e074600f64b0d72b46ec68d03c0ca9180c0 (patch)
tree275a24d253e2243a2e04ca48a5af64ff694ea9b2 /synapse/rest/media/v1/thumbnail_resource.py
parentMerge pull request #2845 from matrix-org/rav/urlcache_error_handling (diff)
parentAdd unit tests (diff)
downloadsynapse-1f881e074600f64b0d72b46ec68d03c0ca9180c0.tar.xz
Merge pull request #2791 from matrix-org/erikj/media_storage_refactor
Ensure media is in local cache before thumbnailing
Diffstat (limited to 'synapse/rest/media/v1/thumbnail_resource.py')
-rw-r--r--synapse/rest/media/v1/thumbnail_resource.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/synapse/rest/media/v1/thumbnail_resource.py b/synapse/rest/media/v1/thumbnail_resource.py
index 12e84a2b7c..58ada49711 100644
--- a/synapse/rest/media/v1/thumbnail_resource.py
+++ b/synapse/rest/media/v1/thumbnail_resource.py
@@ -164,7 +164,8 @@ class ThumbnailResource(Resource):
 
         # Okay, so we generate one.
         file_path = yield self.media_repo.generate_local_exact_thumbnail(
-            media_id, desired_width, desired_height, desired_method, desired_type
+            media_id, desired_width, desired_height, desired_method, desired_type,
+            url_cache=media_info["url_cache"],
         )
 
         if file_path: