diff --git a/js/version/version.js b/js/version/version.js index 9a9a682c..20cbf11a 100644 --- a/js/version/version.js +++ b/js/version/version.js @@ -8,20 +8,14 @@ var version = { */ version.checkVersion = function () { - $.ajax({ - type: 'GET', - url: 'controllers/hash.php', - success: function (data) { + $.getJSON('controllers/hash.php') + .success(function(data) { // The githash variable is located in index.php if (data && data.gitHash !== gitHash) { window.location.reload(); window.location.href = window.location.href; - } - }, - error: function () { - - } - }); + } + }); }