mirror of https://github.com/vector-im/riot-web
Supporting change for CVE-2024-47771 / GHSA-963w-49j9-gxj6
parent
8d7f2b5c13
commit
63c8550791
|
@ -26,6 +26,7 @@ type ElectronChannel =
|
|||
| "userDownloadAction"
|
||||
| "openDesktopCapturerSourcePicker"
|
||||
| "userAccessToken"
|
||||
| "homeserverUrl"
|
||||
| "serverSupportedVersions";
|
||||
|
||||
declare global {
|
||||
|
|
|
@ -126,6 +126,11 @@ export default class ElectronPlatform extends VectorBasePlatform {
|
|||
window.electron!.send("userAccessToken", MatrixClientPeg.get()?.getAccessToken());
|
||||
});
|
||||
|
||||
// `homeserverUrl` (IPC) is requested by the main process. A reply is sent over the same channel.
|
||||
window.electron.on("homeserverUrl", () => {
|
||||
window.electron!.send("homeserverUrl", MatrixClientPeg.get()?.getHomeserverUrl());
|
||||
});
|
||||
|
||||
// `serverSupportedVersions` is requested by the main process when it needs to know if the
|
||||
// server supports a particular version. This is primarily used to detect authenticated media
|
||||
// support. A reply is sent over the same channel.
|
||||
|
|
Loading…
Reference in New Issue