mirror of
https://github.com/discourse/discourse.git
synced 2025-05-29 01:31:35 +08:00
DEV: Import Promise from rsvp (#8296)
This commit is contained in:

committed by
GitHub

parent
94a34af702
commit
014f19b6ea
@ -6,6 +6,7 @@ import { propertyNotEqual } from "discourse/lib/computed";
|
||||
import { popupAjaxError } from "discourse/lib/ajax-error";
|
||||
import Group from "discourse/models/group";
|
||||
import { userPath } from "discourse/lib/url";
|
||||
import { Promise } from "rsvp";
|
||||
|
||||
const wrapAdmin = user => (user ? AdminUser.create(user) : null);
|
||||
|
||||
@ -503,7 +504,7 @@ const AdminUser = Discourse.User.extend({
|
||||
|
||||
loadDetails() {
|
||||
if (this.loadedDetails) {
|
||||
return Ember.RSVP.resolve(this);
|
||||
return Promise.resolve(this);
|
||||
}
|
||||
|
||||
return AdminUser.find(this.id).then(result => {
|
||||
|
Reference in New Issue
Block a user