diff options
author | hmhealey <harrisonmhealey@gmail.com> | 2015-07-27 10:44:53 -0400 |
---|---|---|
committer | hmhealey <harrisonmhealey@gmail.com> | 2015-07-27 15:01:15 -0400 |
commit | a3cbe598fb6732be92bdd7e54cedc7737a513c34 (patch) | |
tree | c24d4d1a8af20fb7c43620e54bdccd54a36ab85e | |
parent | 85ff151b71a5b0a488b7a8c3f0978b5d0ee8e280 (diff) | |
download | chat-a3cbe598fb6732be92bdd7e54cedc7737a513c34.tar.gz chat-a3cbe598fb6732be92bdd7e54cedc7737a513c34.tar.bz2 chat-a3cbe598fb6732be92bdd7e54cedc7737a513c34.zip |
Replaced instance of String.prototype.startsWith which only works in browsers that support ES6
-rw-r--r-- | web/react/components/create_post.jsx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/web/react/components/create_post.jsx b/web/react/components/create_post.jsx index 87895588e..327520210 100644 --- a/web/react/components/create_post.jsx +++ b/web/react/components/create_post.jsx @@ -32,7 +32,7 @@ module.exports = React.createClass({ post.message = this.state.messageText; // if this is a reply, trim off any carets from the beginning of a message - if (this.state.rootId && post.message.startsWith("^")) { + if (this.state.rootId && post.message[0] === "^") { post.message = post.message.replace(/^\^+\s*/g, ""); } |