summary refs log tree commit diff
path: root/synapse/rest/media/v1/thumbnail_resource.py
diff options
context:
space:
mode:
authorErik Johnston <erik@matrix.org>2018-01-16 10:52:32 +0000
committerErik Johnston <erik@matrix.org>2018-01-18 12:00:46 +0000
commit4a53f3a3e8fb7fe9df052790858ca3f7dbff78f9 (patch)
tree844413553de19bc862a25281d8d68835d63c74d1 /synapse/rest/media/v1/thumbnail_resource.py
parentDo logcontexts correctly (diff)
downloadsynapse-4a53f3a3e8fb7fe9df052790858ca3f7dbff78f9.tar.xz
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 8c9653843b..49e4af514c 100644
--- a/synapse/rest/media/v1/thumbnail_resource.py
+++ b/synapse/rest/media/v1/thumbnail_resource.py
@@ -162,7 +162,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: