From 761da7d380d20e0ba78373a755e28882ab1fcc43 Mon Sep 17 00:00:00 2001 From: Benjamin Brent Date: Sun, 1 Dec 2013 13:30:41 +1100 Subject: [PATCH] Fix email_preview AJAX call to use Discourse.ajax --- app/assets/javascripts/admin/models/email_preview.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/assets/javascripts/admin/models/email_preview.js b/app/assets/javascripts/admin/models/email_preview.js index 1650674eb..0390a48af 100644 --- a/app/assets/javascripts/admin/models/email_preview.js +++ b/app/assets/javascripts/admin/models/email_preview.js @@ -10,7 +10,7 @@ Discourse.EmailPreview = Discourse.Model.extend({}); Discourse.EmailPreview.reopenClass({ findDigest: function(last_seen_at) { - return $.ajax("/admin/email/preview-digest.json", { + return Discourse.ajax("/admin/email/preview-digest.json", { data: {last_seen_at: last_seen_at} }).then(function (result) { return Discourse.EmailPreview.create(result);