mirror of
https://github.com/vector-im/element-web.git
synced 2024-11-17 14:05:04 +08:00
Hide e2e features if not enabled
Don't show the device info in the MemberInfo and UserSettings unless the user has ticked the 'labs' box.
This commit is contained in:
parent
3312a4d57e
commit
e973d18085
@ -258,6 +258,10 @@ module.exports = React.createClass({
|
||||
},
|
||||
|
||||
_renderDeviceInfo: function() {
|
||||
if (!UserSettingsStore.isFeatureEnabled("e2e_encryption")) {
|
||||
return null;
|
||||
}
|
||||
|
||||
var client = MatrixClientPeg.get();
|
||||
var deviceId = client.deviceId;
|
||||
var olmKey = client.getDeviceEd25519Key() || "<not supported>";
|
||||
|
@ -30,6 +30,7 @@ var MatrixClientPeg = require("../../../MatrixClientPeg");
|
||||
var dis = require("../../../dispatcher");
|
||||
var Modal = require("../../../Modal");
|
||||
var sdk = require('../../../index');
|
||||
var UserSettingsStore = require('../../../UserSettingsStore');
|
||||
var createRoom = require('../../../createRoom');
|
||||
|
||||
module.exports = React.createClass({
|
||||
@ -506,6 +507,10 @@ module.exports = React.createClass({
|
||||
},
|
||||
|
||||
_renderDevices: function() {
|
||||
if (!UserSettingsStore.isFeatureEnabled("e2e_encryption")) {
|
||||
return null;
|
||||
}
|
||||
|
||||
var devices = this.state.devices;
|
||||
var MemberDeviceInfo = sdk.getComponent('rooms.MemberDeviceInfo');
|
||||
var Spinner = sdk.getComponent("elements.Spinner");
|
||||
|
Loading…
Reference in New Issue
Block a user