From 4cbb7e98323ac05559ee08a0583fea2aa056b955 Mon Sep 17 00:00:00 2001 From: psychobunny Date: Thu, 9 Oct 2014 18:26:59 -0400 Subject: [PATCH] closes #2230 and I actually tested every single one. go me! --- public/src/client/users.js | 9 +++------ 1 file changed, 3 insertions(+), 6 deletions(-) diff --git a/public/src/client/users.js b/public/src/client/users.js index 858b7d70d8..a1e852bb9f 100644 --- a/public/src/client/users.js +++ b/public/src/client/users.js @@ -76,9 +76,7 @@ define('forum/users', function() { return !$('.users-box[data-uid="' + user.uid + '"]').length; }); - ajaxify.loadTemplate('users', function(usersTemplate) { - var html = templates.parse(templates.getBlock(usersTemplate, 'users'), {users: users}); - + templates.parse('users', 'users', {users: users}, function(html) { translator.translate(html, function(translated) { $('#users-container').append(translated); $('#users-container .anon-user').appendTo($('#users-container')); @@ -128,11 +126,10 @@ define('forum/users', function() { return; } - ajaxify.loadTemplate('users', function(usersTemplate) { - var html = templates.parse(templates.getBlock(usersTemplate, 'users'), data); - + templates.parse('users', 'users', data, function(html) { translator.translate(html, function(translated) { $('#users-container').html(translated); + if (!data.users.length) { translator.translate('[[error:no-user]]', function(translated) { notify.html(translated);