Skip to content

Commit

Permalink
iclude project function to handle errors
Browse files Browse the repository at this point in the history
e.g. to re-authorize
Cf. dariok/wienerdiarium#25
Cf. #3
  • Loading branch information
dariok committed Nov 22, 2018
1 parent de0cda3 commit ac8d100
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions form.js
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,9 @@ $.ajax({
return {
results: process(data)
};
},
error: function ( jqXHR, textStatus, errorThrown ) {
handleError ( jqXHR, textStatus, errorThrown );
}
}
});
Expand Down
4 changes: 4 additions & 0 deletions process.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,4 +16,8 @@ function queryString (conf, params) {
"_type": "query"
}
return query
}

function handleError (jqXHR, textStatus, errorThrown) {
console.log(jqXHR + " – " + textStatus + " – " + errorThrown);
}

0 comments on commit ac8d100

Please sign in to comment.