From: jordan Date: Fri, 23 Sep 2011 14:46:37 +0000 (+0000) Subject: be able to execute JavaScript post-action commands even if the success status equals... X-Git-Tag: live~141 X-Git-Url: https://git.openstreetmap.org./osqa.git/commitdiff_plain/b728fbfb95442d9bf06e291747e9cd0b59dae612 be able to execute JavaScript post-action commands even if the success status equals False git-svn-id: http://svn.osqa.net/svnroot/osqa/trunk@1176 0cfe37f9-358a-4d5e-be75-b63607b5c754 --- diff --git a/forum/skins/default/media/js/osqa.main.js b/forum/skins/default/media/js/osqa.main.js index 0c16eea..8fb4d63 100644 --- a/forum/skins/default/media/js/osqa.main.js +++ b/forum/skins/default/media/js/osqa.main.js @@ -331,7 +331,8 @@ function process_ajax_response(data, evt, callback) { if (!data.success && data['error_message'] != undefined) { show_message(evt, data.error_message, function() {if (callback) callback(true);}); end_command(false); - } else if (typeof data['commands'] != undefined){ + } + if (typeof data['commands'] != undefined){ for (var command in data.commands) { response_commands[command].apply(null, data.commands[command])