mattermost-mobile/app/components/post_draft/quick_actions/index.js
Claudio Costa 846aa759b2
[MM-31257] Bump max allowed file uploads per post (#5552)
* Bump max allowed file uploads per post

* Update error string
2021-08-24 18:23:38 +02:00

21 lines
736 B
JavaScript

// Copyright (c) 2015-present Mattermost, Inc. All Rights Reserved.
// See LICENSE.txt for license information.
import {connect} from 'react-redux';
import {canUploadFilesOnMobile, getConfig, getServerVersion} from '@mm-redux/selectors/entities/general';
import {getAllowedServerMaxFileSize, getMaxFileCount} from '@utils/file';
import QuickActions from './quick_actions';
function mapStateToProps(state) {
const config = getConfig(state);
return {
canUploadFiles: canUploadFilesOnMobile(state),
maxFileSize: getAllowedServerMaxFileSize(config),
maxFileCount: getMaxFileCount(getServerVersion(state)),
};
}
export default connect(mapStateToProps, null, null, {forwardRef: true})(QuickActions);