about summary refs log tree commit diff
path: root/app/assets
diff options
context:
space:
mode:
Diffstat (limited to 'app/assets')
-rw-r--r--app/assets/javascripts/components/components/status_content.jsx2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/assets/javascripts/components/components/status_content.jsx b/app/assets/javascripts/components/components/status_content.jsx
index 118635ed3..43b868fc0 100644
--- a/app/assets/javascripts/components/components/status_content.jsx
+++ b/app/assets/javascripts/components/components/status_content.jsx
@@ -23,7 +23,7 @@ const StatusContent = React.createClass({
 
       if (mention) {
         link.addEventListener('click', this.onMentionClick.bind(this, mention), false);
-      } else if (link.text[0] === '#' || (link.previousSibling && link.previousSibling.text[link.previousSibling.text.length - 1] === '#')) {
+      } else if (link.text[0] === '#' || (link.previousSibling && link.previousSibling.text && link.previousSibling.text[link.previousSibling.text.length - 1] === '#')) {
         link.addEventListener('click', this.onHashtagClick.bind(this, link.text), false);
       } else {
         link.setAttribute('target', '_blank');