Skip to content

Commit

Permalink
check response earlier
Browse files Browse the repository at this point in the history
  • Loading branch information
birm authored Jan 9, 2025
1 parent 773753c commit 9fee5fc
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions common/PathdbMods.js
Original file line number Diff line number Diff line change
Expand Up @@ -102,8 +102,9 @@ async function PathDbMods() {
'Authorization': 'Bearer ' + getCookie("token"),
})
}).then(function(response) {
console.log(response);
if (!response.ok)
console.log("response not ok", response.statusText)
console.log("response not ok", response.statusText);
return {
error: !response.ok,
text: response.statusText,
Expand All @@ -122,8 +123,9 @@ async function PathDbMods() {
'Authorization': 'Bearer ' + getCookie("token"),
})
}).then(function(response) {
console.log(response);
if (!response.ok)
console.log("response not ok", response.statusText)
console.log("response not ok", response.statusText);
return {
error: !response.ok,
text: response.statusText,
Expand Down

0 comments on commit 9fee5fc

Please sign in to comment.