diff --git a/src/components/mention_link/mention_link.js b/src/components/mention_link/mention_link.js index 6515bd11..4e1ec23d 100644 --- a/src/components/mention_link/mention_link.js +++ b/src/components/mention_link/mention_link.js @@ -53,7 +53,9 @@ const MentionLink = { this.$router.push(link) }, handleSelection () { - this.hasSelection = document.getSelection().containsNode(this.$refs.full, true) + if (this.$refs.full) { + this.hasSelection = document.getSelection().containsNode(this.$refs.full, true) + } } }, mounted () {