From 58fa6d3fc64c789a10f407532c0e7c419b0c1650 Mon Sep 17 00:00:00 2001 From: Mark Haines Date: Mon, 15 Dec 2014 13:53:58 +0000 Subject: return an mxc uri rather than a content_token. --- synapse/media/v1/upload_resource.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/synapse/media/v1/upload_resource.py b/synapse/media/v1/upload_resource.py index b2449ff03d..5645b0df46 100644 --- a/synapse/media/v1/upload_resource.py +++ b/synapse/media/v1/upload_resource.py @@ -95,8 +95,10 @@ class UploadResource(BaseMediaResource): yield self._generate_local_thumbnails(media_id, media_info) + content_uri = "mxc://%s/%s" % (self.server_name, media_id) + respond_with_json( - request, 200, {"content_token": media_id}, send_cors=True + request, 200, {"content_uri": content_uri}, send_cors=True ) except CodeMessageException as e: logger.exception(e) -- cgit 1.4.1