DEV: Import getURL to fix deprecation warnings (#16)

This commit is contained in:
Mark VanLandingham 2020-07-07 13:50:16 -05:00 committed by GitHub
parent 3e6d8734de
commit 8bcb7aa93c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 1 deletions

View File

@ -1,6 +1,7 @@
import discourseComputed from "discourse-common/utils/decorators"; import discourseComputed from "discourse-common/utils/decorators";
import { ajax } from "discourse/lib/ajax"; import { ajax } from "discourse/lib/ajax";
import EmberObject from "@ember/object"; import EmberObject from "@ember/object";
import getURL from "discourse-common/lib/get-url";
const AdminSubscription = EmberObject.extend({ const AdminSubscription = EmberObject.extend({
@discourseComputed("status") @discourseComputed("status")
@ -15,7 +16,7 @@ const AdminSubscription = EmberObject.extend({
@discourseComputed("metadata") @discourseComputed("metadata")
subscriptionUserPath(metadata) { subscriptionUserPath(metadata) {
return Discourse.getURL( return getURL(
`/admin/users/${metadata.user_id}/${metadata.username}` `/admin/users/${metadata.user_id}/${metadata.username}`
); );
}, },