From 6287c8e1712d176ea95ccfafe39b2f8515a6578e Mon Sep 17 00:00:00 2001 From: Jarek Radosz Date: Fri, 14 Aug 2020 15:20:57 +0200 Subject: [PATCH] FIX: A paste event listener was re-added instead of being removed MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit cc: @eviltrout 😉 --- .../javascripts/discourse/app/components/user-selector.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/javascripts/discourse/app/components/user-selector.js b/app/assets/javascripts/discourse/app/components/user-selector.js index a340b27f18f..b97788fed05 100644 --- a/app/assets/javascripts/discourse/app/components/user-selector.js +++ b/app/assets/javascripts/discourse/app/components/user-selector.js @@ -43,7 +43,7 @@ export default TextField.extend({ @on("willDestroyElement") _destroyAutocompleteInstance() { $(this.element).autocomplete("destroy"); - this.element.addEventListener("paste", this._paste); + this.element.removeEventListener("paste", this._paste); }, @on("didInsertElement")