Skip to content

Commit

Permalink
MM-11782: Make archived channels experimental and off by default. (ma…
Browse files Browse the repository at this point in the history
  • Loading branch information
grundleborg authored and cpanato committed Aug 22, 2018
1 parent 27c7af1 commit 9139ea0
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 10 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -101,7 +101,7 @@ export class UsersAndTeamsSettings extends AdminSettings {
this.state.edited.maxChannelsPerTeam ||
this.state.edited.maxNotificationsPerChannel ||
this.state.edited.enableConfirmNotificationsToChannel ||
this.state.edited.viewArchivedChannels
this.state.edited.experimentalViewArchivedChannels
);

if (configFieldEdited) {
Expand Down Expand Up @@ -169,7 +169,7 @@ export class UsersAndTeamsSettings extends AdminSettings {
this.state.edited.maxChannelsPerTeam,
this.state.edited.maxNotificationsPerChannel,
this.state.edited.enableConfirmNotificationsToChannel,
this.state.edited.viewArchivedChannels,
this.state.edited.experimentalViewArchivedChannels,
].filter((v) => v).join(', '),
}}
/>
Expand Down Expand Up @@ -211,7 +211,7 @@ export class UsersAndTeamsSettings extends AdminSettings {
config.TeamSettings.MaxChannelsPerTeam = this.parseIntNonZero(this.state.maxChannelsPerTeam, Constants.DEFAULT_MAX_CHANNELS_PER_TEAM);
config.TeamSettings.MaxNotificationsPerChannel = this.parseIntNonZero(this.state.maxNotificationsPerChannel, Constants.DEFAULT_MAX_NOTIFICATIONS_PER_CHANNEL);
config.TeamSettings.EnableConfirmNotificationsToChannel = this.state.enableConfirmNotificationsToChannel;
config.TeamSettings.ViewArchivedChannels = this.state.viewArchivedChannels;
config.TeamSettings.ExperimentalViewArchivedChannels = this.state.experimentalViewArchivedChannels;
return config;
};

Expand All @@ -225,7 +225,7 @@ export class UsersAndTeamsSettings extends AdminSettings {
maxChannelsPerTeam: config.TeamSettings.MaxChannelsPerTeam,
maxNotificationsPerChannel: config.TeamSettings.MaxNotificationsPerChannel,
enableConfirmNotificationsToChannel: config.TeamSettings.EnableConfirmNotificationsToChannel,
viewArchivedChannels: config.TeamSettings.ViewArchivedChannels,
experimentalViewArchivedChannels: config.TeamSettings.ExperimentalViewArchivedChannels,
};
}

Expand Down Expand Up @@ -421,7 +421,7 @@ export class UsersAndTeamsSettings extends AdminSettings {
setByEnv={this.isSetByEnv('TeamSetting.TeammateNameDisplay')}
/>
<BooleanSetting
id='viewArchivedChannels'
id='experimentalViewArchivedChannels'
label={
<FormattedMessage
id='admin.viewArchivedChannelsTitle'
Expand All @@ -431,12 +431,12 @@ export class UsersAndTeamsSettings extends AdminSettings {
helpText={
<FormattedMessage
id='admin.viewArchivedChannelsHelpText'
defaultMessage='When true, allows users to share permalinks and search for content of channels that have been archived. Users can only view the content in channels of which they were a member before the channel was archived.'
defaultMessage='(Experimental) When true, allows users to share permalinks and search for content of channels that have been archived. Users can only view the content in channels of which they were a member before the channel was archived.'
/>
}
value={this.state.viewArchivedChannels}
value={this.state.experimentalViewArchivedChannels}
onChange={this.handleChange}
setByEnv={this.isSetByEnv('TeamSetting.ViewArchivedChannels')}
setByEnv={this.isSetByEnv('TeamSetting.ExperimentalViewArchivedChannels')}
/>
</SettingsGroup>
);
Expand Down
2 changes: 1 addition & 1 deletion components/delete_channel_modal/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ function mapStateToProps(state) {
const config = getConfig(state);

return {
canViewArchivedChannels: config.ViewArchivedChannels === 'true',
canViewArchivedChannels: config.ExperimentalViewArchivedChannels === 'true',
currentTeamDetails: getCurrentTeam(state),
};
}
Expand Down
2 changes: 1 addition & 1 deletion i18n/en.json
Original file line number Diff line number Diff line change
Expand Up @@ -1369,7 +1369,7 @@
"admin.user_item.userAccessTokenPostAll": "(with post:all personal access tokens)",
"admin.user_item.userAccessTokenPostAllPublic": "(with post:channels personal access tokens)",
"admin.user_item.userAccessTokenYes": "(with personal access tokens)",
"admin.viewArchivedChannelsHelpText": "When true, allows users to share permalinks and search for content of channels that have been archived. Users can only view the content in channels of which they were a member before the channel was archived.",
"admin.viewArchivedChannelsHelpText": "(Experimental) When true, allows users to share permalinks and search for content of channels that have been archived. Users can only view the content in channels of which they were a member before the channel was archived.",
"admin.viewArchivedChannelsTitle": "Allow users to view archived channels:",
"admin.webrtc.enableDescription": "When true, Mattermost allows making **one-on-one** video calls. WebRTC calls are available on Chrome, Firefox and Mattermost Desktop Apps.",
"admin.webrtc.enableTitle": "Enable Mattermost WebRTC: ",
Expand Down

0 comments on commit 9139ea0

Please sign in to comment.