1
0
mirror of https://github.com/matrix-org/matrix-react-sdk.git synced 2025-07-25 17:02:04 +03:00

Change new session toast to unverified

This also changes text to show the device ID and name in the toast.

Fixes https://github.com/vector-im/riot-web/issues/11916
This commit is contained in:
J. Ryan Stinnett
2020-01-29 15:00:01 +00:00
parent 6d47f9620f
commit f12fe984e5
4 changed files with 24 additions and 15 deletions

View File

@ -21,7 +21,7 @@ import { _t } from './languageHandler';
import ToastStore from './stores/ToastStore';
function toastKey(deviceId) {
return 'newsession_' + deviceId;
return 'unverified_session_' + deviceId;
}
const KEY_BACKUP_POLL_INTERVAL = 5 * 60 * 1000;
@ -160,10 +160,10 @@ export default class DeviceListener {
this._activeNagToasts.add(device.deviceId);
ToastStore.sharedInstance().addOrReplaceToast({
key: toastKey(device.deviceId),
title: _t("New Session"),
title: _t("Unverified session"),
icon: "verification_warning",
props: {deviceId: device.deviceId},
component: sdk.getComponent("toasts.NewSessionToast"),
props: { device },
component: sdk.getComponent("toasts.UnverifiedSessionToast"),
});
newActiveToasts.add(device.deviceId);
}