Skip to content

Commit

Permalink
Merge branch 'swap_try_except_to_decorator' of https://github.com/Neu…
Browse files Browse the repository at this point in the history
…rodataWithoutBorders/nwb-guide into swap_try_except_to_decorator
  • Loading branch information
garrettmflynn committed May 29, 2024
2 parents 8c93b4f + 874f48c commit 75a7670
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -80,11 +80,10 @@ export class GuidedSourceDataPage extends ManagedPage {
heightAuto: false,
backdrop: "rgba(0,0,0, 0.4)",
timerProgressBar: false,
didOpen: () => Swal.showLoading()
didOpen: () => Swal.showLoading(),
});
};


setTimeout(() => {
if (stillFireSwal) fireSwal();
});
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ export const run = async (pathname, payload, options = {}) => {
// Clear private keys from being passed
payload = sanitize(structuredClone(payload));

console.warn('FETCH?')
console.warn("FETCH?");
const results = await fetch(new URL(pathname, baseUrl), {
method: "POST",
headers: { "Content-Type": "application/json" },
Expand All @@ -84,7 +84,7 @@ export const run = async (pathname, payload, options = {}) => {
})
.then(async (res) => {
const json = await res.json();
console.warn('FETCH!', json)
console.warn("FETCH!", json);

if (!res.ok) {
const message = json.message;
Expand All @@ -95,11 +95,10 @@ export const run = async (pathname, payload, options = {}) => {
return json;
})
.finally(() => {
console.warn('CANCEL?')
console.warn("CANCEL?");
if (internalSwal) Swal.close();
});


return results || true;
};

Expand Down

0 comments on commit 75a7670

Please sign in to comment.