summaryrefslogtreecommitdiffstats
path: root/web/react/components
diff options
context:
space:
mode:
authorJoramWilander <jwawilander@gmail.com>2015-06-18 17:39:12 -0400
committerJoramWilander <jwawilander@gmail.com>2015-06-18 17:39:12 -0400
commit0802c55aad51fd3434b3529c190181431e7241d9 (patch)
tree3517d43f657d222325580fc77884e8279ffee0ca /web/react/components
parent423a862af9b9a173ef274376b54e146447f598d9 (diff)
downloadchat-0802c55aad51fd3434b3529c190181431e7241d9.tar.gz
chat-0802c55aad51fd3434b3529c190181431e7241d9.tar.bz2
chat-0802c55aad51fd3434b3529c190181431e7241d9.zip
fixes br tags causing new lines
Diffstat (limited to 'web/react/components')
-rw-r--r--web/react/components/create_post.jsx4
1 files changed, 1 insertions, 3 deletions
diff --git a/web/react/components/create_post.jsx b/web/react/components/create_post.jsx
index 191be9bf8..a534e495d 100644
--- a/web/react/components/create_post.jsx
+++ b/web/react/components/create_post.jsx
@@ -31,9 +31,7 @@ module.exports = React.createClass({
post.message = this.state.messageText;
- var repRegex = new RegExp("<br>", "g");
- if (post.message.replace(repRegex, " ").trim().length === 0
- && this.state.previews.length === 0) {
+ if (post.message.trim().length === 0 && this.state.previews.length === 0) {
return;
}