From 3af224ed398b97cc44e007c3878482d711517a7e Mon Sep 17 00:00:00 2001 From: JT Turner Date: Tue, 5 Jan 2016 23:31:46 -0800 Subject: [PATCH] Fix ghost_head helper to not run if error page. issue #6289 - Made quick fix to return from ghost_head helper if error page --- core/server/helpers/ghost_head.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/core/server/helpers/ghost_head.js b/core/server/helpers/ghost_head.js index 0ae312f622..2aaf0282b4 100644 --- a/core/server/helpers/ghost_head.js +++ b/core/server/helpers/ghost_head.js @@ -289,6 +289,11 @@ function getAjaxHelper(clientId, clientSecret) { } ghost_head = function (options) { + // if error page do nothing + if (this.code >= 400) { + return; + } + // create a shortcut for theme config blog = config.theme;