mirror of
https://github.com/rr-/szurubooru.git
synced 2025-07-17 08:26:24 +00:00
Fixed promises and its race conditions
This commit is contained in:
@ -18,7 +18,7 @@ App.Presenters.UserListPresenter = function(
|
||||
topNavigationPresenter.select('users');
|
||||
topNavigationPresenter.changeTitle('Users');
|
||||
|
||||
promise.waitAll(
|
||||
promise.wait(
|
||||
util.promiseTemplate('user-list'),
|
||||
util.promiseTemplate('user-list-item'))
|
||||
.then(function(listHtml, itemHtml) {
|
||||
@ -55,6 +55,10 @@ App.Presenters.UserListPresenter = function(
|
||||
order: searchArgs.order}});
|
||||
}
|
||||
|
||||
function deinit() {
|
||||
pagerPresenter.deinit();
|
||||
}
|
||||
|
||||
function render() {
|
||||
$el.html(listTemplate());
|
||||
$el.find('.order a').click(orderLinkClicked);
|
||||
@ -93,6 +97,7 @@ App.Presenters.UserListPresenter = function(
|
||||
return {
|
||||
init: init,
|
||||
reinit: reinit,
|
||||
deinit: deinit,
|
||||
render: render,
|
||||
};
|
||||
|
||||
|
Reference in New Issue
Block a user