Show links to media content from local users and reports (#508)

Change-Id: Ia8993470a9dd5e479c028013b5be6723f569814d
This commit is contained in:
Alexander Tumin
2024-04-20 10:29:44 +03:00
committed by Manuel Stahl
parent 531d8f2d7f
commit c6f9dbec18
6 changed files with 78 additions and 2 deletions

View File

@@ -53,3 +53,8 @@ export const getSupportedLoginFlows = async baseUrl => {
const response = await fetchUtils.fetchJson(loginFlowsUrl, { method: "GET" });
return response.json.flows;
};
export const getMediaUrl = media_id => {
const baseUrl = localStorage.getItem("base_url");
return `${baseUrl}/_matrix/media/v1/download/${media_id}?allow_redirect=true`;
};