FIX: prevents exception when the node doesnt exist anymore (#7408)

FIX: prevents exception when the node doesnt exist anymore (#7408)

diff --git a/app/assets/javascripts/discourse/components/text-overflow.js.es6 b/app/assets/javascripts/discourse/components/text-overflow.js.es6
index 905ae32..402b3a9 100644
--- a/app/assets/javascripts/discourse/components/text-overflow.js.es6
+++ b/app/assets/javascripts/discourse/components/text-overflow.js.es6
@@ -2,10 +2,12 @@ export default Ember.Component.extend({
   didInsertElement() {
     this._super(...arguments);
     Ember.run.next(null, () => {
-      this.$()
-        .find("hr")
-        .remove();
-      this.$().ellipsis();
+      const $this = this.$();
+
+      if ($this) {
+        $this.find("hr").remove();
+        $this.ellipsis();
+      }
     });
   }
 });

GitHub sha: 151da50e