diff options
author | Erik Johnston <erik@matrix.org> | 2016-06-29 14:57:59 +0100 |
---|---|---|
committer | Erik Johnston <erik@matrix.org> | 2016-06-29 14:57:59 +0100 |
commit | a70688445dd7a9fa41a55a642fb9a394f291ae45 (patch) | |
tree | 780be0bce7d1f48decb341bd665237435b992bda /synapse/rest/media/v1/filepath.py | |
parent | Track approximate last access time for remote media (diff) | |
download | synapse-a70688445dd7a9fa41a55a642fb9a394f291ae45.tar.xz |
Implement purge_media_cache admin API
Diffstat (limited to 'synapse/rest/media/v1/filepath.py')
-rw-r--r-- | synapse/rest/media/v1/filepath.py | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/synapse/rest/media/v1/filepath.py b/synapse/rest/media/v1/filepath.py index 422ab86fb3..0137458f71 100644 --- a/synapse/rest/media/v1/filepath.py +++ b/synapse/rest/media/v1/filepath.py @@ -65,3 +65,9 @@ class MediaFilePaths(object): file_id[0:2], file_id[2:4], file_id[4:], file_name ) + + def remote_media_thumbnail_dir(self, server_name, file_id): + return os.path.join( + self.base_path, "remote_thumbnail", server_name, + file_id[0:2], file_id[2:4], file_id[4:], + ) |