diff --git a/app/assets/javascripts/admin/models/admin_dashboard.js b/app/assets/javascripts/admin/models/admin_dashboard.js index 14b03e8494d..4aaf0984687 100644 --- a/app/assets/javascripts/admin/models/admin_dashboard.js +++ b/app/assets/javascripts/admin/models/admin_dashboard.js @@ -19,7 +19,7 @@ Discourse.AdminDashboard.reopenClass({ @return {jqXHR} a jQuery Promise object **/ find: function() { - return Discourse.ajax("/admin/dashboard").then(function(json) { + return Discourse.ajax("/admin/dashboard.json").then(function(json) { var model = Discourse.AdminDashboard.create(json); model.set('loaded', true); return model; @@ -34,7 +34,7 @@ Discourse.AdminDashboard.reopenClass({ @return {jqXHR} a jQuery Promise object **/ fetchProblems: function() { - return Discourse.ajax("/admin/dashboard/problems", { + return Discourse.ajax("/admin/dashboard/problems.json", { type: 'GET', dataType: 'json' }).then(function(json) { diff --git a/app/assets/javascripts/admin/models/admin_user.js b/app/assets/javascripts/admin/models/admin_user.js index a55873a619e..068eec8aa18 100644 --- a/app/assets/javascripts/admin/models/admin_user.js +++ b/app/assets/javascripts/admin/models/admin_user.js @@ -388,7 +388,7 @@ Discourse.AdminUser.reopenClass({ }, find: function(username) { - return Discourse.ajax("/admin/users/" + username).then(function (result) { + return Discourse.ajax("/admin/users/" + username + ".json").then(function (result) { result.loadedDetails = true; return Discourse.AdminUser.create(result); });