From 979e5754a5ca7601f573957a69971b4e37bf869a Mon Sep 17 00:00:00 2001 From: ctrlcctrlv Date: Sat, 17 Aug 2013 19:08:54 +0000 Subject: Better error handling --- js/oekaki.js | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'js') diff --git a/js/oekaki.js b/js/oekaki.js index c610dd6b..2ff17fc7 100644 --- a/js/oekaki.js +++ b/js/oekaki.js @@ -254,10 +254,9 @@ $("form[name='post']").on("submit", function(e){ processData: false, contentType: false, success: function(data) { - //location.reload(); - console.log(data); + location.reload(); }, - error: function(data) {alert("Something went wrong!"); console.log(data)} + error: function(jq, data) {alert($('h2',jq.responseText).text());} }); } -- cgit v1.3