FIX: adds auto-route to avoid losing queryParams on successive clicks

approved
#1

FIX: adds auto-route to avoid losing queryParams on successive clicks

diff --git a/assets/javascripts/discourse-assign/initializers/extend-for-assigns.js.es6 b/assets/javascripts/discourse-assign/initializers/extend-for-assigns.js.es6
index a2302e3..1fddd87 100644
--- a/assets/javascripts/discourse-assign/initializers/extend-for-assigns.js.es6
+++ b/assets/javascripts/discourse-assign/initializers/extend-for-assigns.js.es6
@@ -138,7 +138,7 @@ function initialize(api) {
     const assignedTo = topic.get("assigned_to_user.username");
     if (assignedTo) {
       const assignedPath = topic.get("assignedToUserPath");
-      return `<a class='assigned-to discourse-tag simple' href='${assignedPath}'>${iconHTML(
+      return `<a data-auto-route='true' class='assigned-to discourse-tag simple' href='${assignedPath}'>${iconHTML(
         "user-plus"
       )}${assignedTo}</a>`;
     }

GitHub sha: 046f1db4

1 Like
Approved #2