Removed Get Team Invite Link link when user creation is disabled

Этот коммит содержится в:
Harrison Healey
2016-03-03 16:01:41 -05:00
родитель a413c8ffa6
Коммит 31238f1d3a
2 изменённых файлов: 10 добавлений и 15 удалений

Просмотреть файл

@@ -41,8 +41,6 @@ export default class GetLinkModal extends React.Component {
}
render() {
const userCreationEnabled = global.window.mm_config.EnableUserCreation === 'true';
let helpText = null;
if (this.props.helpText) {
helpText = (
@@ -55,7 +53,7 @@ export default class GetLinkModal extends React.Component {
}
let copyLink = null;
if (userCreationEnabled && document.queryCommandSupported('copy')) {
if (document.queryCommandSupported('copy')) {
copyLink = (
<button
data-copy-btn='true'
@@ -71,17 +69,14 @@ export default class GetLinkModal extends React.Component {
);
}
let linkText = null;
if (userCreationEnabled) {
linkText = (
<textarea
className='form-control no-resize min-height'
readOnly='true'
ref='textarea'
value={this.props.link}
/>
);
}
const linkText = (
<textarea
className='form-control no-resize min-height'
readOnly='true'
ref='textarea'
value={this.props.link}
/>
);
var copyLinkConfirm = null;
if (this.state.copiedLink) {

Просмотреть файл

@@ -107,7 +107,7 @@ export default class NavbarDropdown extends React.Component {
</li>
);
if (this.props.teamType === Constants.OPEN_TEAM) {
if (this.props.teamType === Constants.OPEN_TEAM && global.window.mm_config.EnableUserCreation === 'true') {
teamLink = (
<li>
<a