Import getURL to fix deprecation warnings (#72)

Import getURL to fix deprecation warnings (#72)

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 6c0f90f..aafda26 100644
--- a/assets/javascripts/discourse-assign/initializers/extend-for-assigns.js.es6
+++ b/assets/javascripts/discourse-assign/initializers/extend-for-assigns.js.es6
@@ -6,6 +6,7 @@ import { h } from "virtual-dom";
 import { iconHTML } from "discourse-common/lib/icon-library";
 import { queryRegistry } from "discourse/widgets/widget";
 import { getOwner } from "discourse-common/lib/get-owner";
+import getURL from "discourse-common/lib/get-url";
 import { htmlSafe } from "@ember/template";
 
 function titleForState(user) {
@@ -102,10 +103,7 @@ function initialize(api) {
     },
     customHref: category => {
       if (category) {
-        return (
-          Discourse.getURL(category.url) +
-          "/l/latest?status=open&assigned=nobody"
-        );
+        return getURL(category.url) + "/l/latest?status=open&assigned=nobody";
       }
     },
     forceActive: (category, args, router) => {
@@ -174,7 +172,7 @@ function initialize(api) {
     @computed("assigned_to_user")
     assignedToUserPath(assignedToUser) {
       const siteSettings = api.container.lookup("site-settings:main");
-      return Discourse.getURL(
+      return getURL(
         siteSettings.assigns_user_url_path.replace(
           "{username}",
           assignedToUser.username
@@ -186,7 +184,7 @@ function initialize(api) {
   api.modifyClass("model:bookmark", {
     @computed("assigned_to_user")
     assignedToUserPath(assignedToUser) {
-      return Discourse.getURL(
+      return getURL(
         this.siteSettings.assigns_user_url_path.replace(
           "{username}",
           assignedToUser.username

GitHub sha: e3a6a641

This commit appears in #72 which was approved by eviltrout. It was merged by markvanlan.