Reuse device_id for synapse-admin on login

Change-Id: I47bbfd1e33ef8bffb618101ae233aeb093cf0ada
This commit is contained in:
Manuel Stahl 2021-05-04 17:10:09 +02:00
parent 41ce58bac8
commit 0bc1ce3226

View file

@ -10,6 +10,7 @@ const authProvider = {
type: "m.login.password",
user: username,
password: password,
device_id: localStorage.getItem("device_id"),
initial_device_display_name: "Synapse Admin",
}),
};
@ -48,7 +49,6 @@ const authProvider = {
if (typeof access_token === "string") {
fetchUtils.fetchJson(logout_api_url, options).then(({ json }) => {
localStorage.removeItem("access_token");
localStorage.removeItem("device_id");
});
}
return Promise.resolve();