diff --git a/frontend/src/components/dialog/share-to-group.js b/frontend/src/components/dialog/share-to-group.js index a922ec915d..a7d0e34118 100644 --- a/frontend/src/components/dialog/share-to-group.js +++ b/frontend/src/components/dialog/share-to-group.js @@ -3,7 +3,7 @@ import PropTypes from 'prop-types'; import { Button } from 'reactstrap'; import Select from 'react-select'; import makeAnimated from 'react-select/lib/animated'; -import { gettext } from '../../utils/constants'; +import { gettext, isPro } from '../../utils/constants'; import { seafileAPI } from '../../utils/seafile-api.js'; import SharePermissionEditor from '../select-editor/share-permission-editor'; @@ -101,7 +101,7 @@ class ShareToGroup extends React.Component { }; this.options = []; this.permissions = ['rw', 'r', 'cloud-edit', 'preview']; - if (this.props.isGroupOwnedRepo) { + if (this.props.isGroupOwnedRepo || !isPro) { this.permissions = ['rw', 'r']; } } diff --git a/frontend/src/components/dialog/share-to-user.js b/frontend/src/components/dialog/share-to-user.js index bf960ccdab..5d07ee0cef 100644 --- a/frontend/src/components/dialog/share-to-user.js +++ b/frontend/src/components/dialog/share-to-user.js @@ -1,7 +1,7 @@ import React, { Fragment } from 'react'; import PropTypes from 'prop-types'; import AsyncSelect from 'react-select/lib/Async'; -import { gettext } from '../../utils/constants'; +import { gettext, isPro } from '../../utils/constants'; import { Button } from 'reactstrap'; import { seafileAPI } from '../../utils/seafile-api.js'; import SharePermissionEditor from '../select-editor/share-permission-editor'; @@ -101,7 +101,7 @@ class ShareToUser extends React.Component { }; this.options = []; this.permissions = ['rw', 'r', 'admin', 'cloud-edit', 'preview']; - if (this.props.isGroupOwnedRepo) { + if (this.props.isGroupOwnedRepo || !isPro) { this.permissions = ['rw', 'r']; } }