Skip to content

Commit

Permalink
PLT-8335 fixing issue with iOS classic (mattermost#579)
Browse files Browse the repository at this point in the history
* PLT-8335 fixing issue with iOS classic

* Fixing eslint errors
  • Loading branch information
coreyhulen authored and GoldUniform committed Jan 10, 2018
1 parent b3116a1 commit 4e271f4
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 5 deletions.
10 changes: 8 additions & 2 deletions components/create_post/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,14 +8,15 @@ import {getCurrentChannel, getCurrentChannelStats} from 'mattermost-redux/select
import {getCurrentUserId} from 'mattermost-redux/selectors/entities/users';
import {get, getBool} from 'mattermost-redux/selectors/entities/preferences';
import {makeGetMessageInHistoryItem, getPost, getMostRecentPostIdInChannel, makeGetCommentCountForPost, getLatestReplyablePostId, getCurrentUsersLatestPost} from 'mattermost-redux/selectors/entities/posts';
import {addMessageIntoHistory, moveHistoryIndexBack, moveHistoryIndexForward, createPost, addReaction, removeReaction} from 'mattermost-redux/actions/posts';
import {addMessageIntoHistory, moveHistoryIndexBack, moveHistoryIndexForward, createPost, createPostImmediately, addReaction, removeReaction} from 'mattermost-redux/actions/posts';
import {Posts} from 'mattermost-redux/constants';

import {setEditingPost} from 'actions/post_actions.jsx';
import {selectPostFromRightHandSideSearchByPostId} from 'actions/views/rhs';
import {makeGetGlobalItem} from 'selectors/storage';
import {setGlobalItem, actionOnGlobalItemsWithPrefix} from 'actions/storage';
import {Preferences, StoragePrefixes} from 'utils/constants.jsx';
import * as UserAgent from 'utils/user_agent';

import CreatePost from './create_post.jsx';

Expand Down Expand Up @@ -52,12 +53,17 @@ function mapStateToProps() {
}

function mapDispatchToProps(dispatch) {
var createPostTemp = createPost;
if (UserAgent.isIosClassic()) {
createPostTemp = createPostImmediately;
}

return {
actions: bindActionCreators({
addMessageIntoHistory,
moveHistoryIndexBack,
moveHistoryIndexForward,
createPost,
createPost: createPostTemp,
addReaction,
removeReaction,
setDraft: setGlobalItem,
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"localforage": "1.5.3",
"localforage-observable": "1.4.0",
"marked": "mattermost/marked#802e981ade71149a497cbe79d12b8a3f82f7657e",
"mattermost-redux": "mattermost/mattermost-redux#767db254e463e3ee99be69b7eec870345daedaf8",
"mattermost-redux": "mattermost/mattermost-redux#c30ae69432a3ce7d73ba6e36cbe4f02e805ecc0c",
"pdfjs-dist": "2.0.106",
"perfect-scrollbar": "0.8.1",
"prop-types": "15.6.0",
Expand Down
4 changes: 2 additions & 2 deletions yarn.lock
Original file line number Diff line number Diff line change
Expand Up @@ -5271,9 +5271,9 @@ math-expression-evaluator@^1.2.14:
version "1.2.16"
resolved "https://registry.yarnpkg.com/math-expression-evaluator/-/math-expression-evaluator-1.2.16.tgz#b357fa1ca9faefb8e48d10c14ef2bcb2d9f0a7c9"

mattermost-redux@mattermost/mattermost-redux#767db254e463e3ee99be69b7eec870345daedaf8:
mattermost-redux@mattermost/mattermost-redux#c30ae69432a3ce7d73ba6e36cbe4f02e805ecc0c:
version "1.1.0"
resolved "https://codeload.github.com/mattermost/mattermost-redux/tar.gz/767db254e463e3ee99be69b7eec870345daedaf8"
resolved "https://codeload.github.com/mattermost/mattermost-redux/tar.gz/c30ae69432a3ce7d73ba6e36cbe4f02e805ecc0c"
dependencies:
deep-equal "1.0.1"
form-data "2.3.1"
Expand Down

0 comments on commit 4e271f4

Please sign in to comment.