diff options
author | Harrison Healey <harrisonmhealey@gmail.com> | 2016-02-23 14:34:06 -0500 |
---|---|---|
committer | Harrison Healey <harrisonmhealey@gmail.com> | 2016-02-23 14:34:06 -0500 |
commit | 0031c6fd1a4df621cbecfd2a2b3efe9a40cd49ce (patch) | |
tree | 2afcb0888267be4cf59df2d0e8f5085d6aacccb0 /web/react/utils | |
parent | 11093ddb51a70622287aac20108be6c6aa2eb76d (diff) | |
parent | 1f049af2b7ea41a5e1e79a8263e10fa58f186c8d (diff) | |
download | chat-0031c6fd1a4df621cbecfd2a2b3efe9a40cd49ce.tar.gz chat-0031c6fd1a4df621cbecfd2a2b3efe9a40cd49ce.tar.bz2 chat-0031c6fd1a4df621cbecfd2a2b3efe9a40cd49ce.zip |
Merge pull request #2229 from mattermost/plt-1770
PLT-1770 Refactor store listeners out of highly used components
Diffstat (limited to 'web/react/utils')
-rw-r--r-- | web/react/utils/utils.jsx | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/web/react/utils/utils.jsx b/web/react/utils/utils.jsx index a4d2515e2..82828e34b 100644 --- a/web/react/utils/utils.jsx +++ b/web/react/utils/utils.jsx @@ -1417,3 +1417,7 @@ export function languages() { export function isPostEphemeral(post) { return post.type === Constants.POST_TYPE_EPHEMERAL || post.state === Constants.POST_DELETED; } + +export function getRootId(post) { + return post.root_id === '' ? post.id : post.root_id; +} |