fix: do not run cleanup and build parallel

fix: UI error toasts
This commit is contained in:
Andras Bacsai
2022-07-08 14:11:18 +02:00
parent d344a9bb4f
commit da11bae67c
18 changed files with 66 additions and 42 deletions

View File

@@ -77,7 +77,7 @@
} else {
await startProxy();
}
} catch ({ error }) {
} catch (error) {
return errorNotification(error);
} finally {
loadingProxy = false;
@@ -88,7 +88,7 @@
try {
await post(`/destinations/${id}/stop`, { engine: destination.engine });
return toast.push($t('destination.coolify_proxy_stopped'));
} catch ({ error }) {
} catch (error) {
return errorNotification(error);
}
}
@@ -96,7 +96,7 @@
try {
await post(`/destinations/${id}/start`, { engine: destination.engine });
return toast.push($t('destination.coolify_proxy_started'));
} catch ({ error }) {
} catch (error) {
return errorNotification(error);
}
}
@@ -110,7 +110,7 @@
engine: destination.engine,
fqdn: settings.fqdn
});
} catch ({ error }) {
} catch (error) {
setTimeout(() => {
window.location.reload();
}, 5000);

View File

@@ -82,7 +82,7 @@ import { appSession } from '$lib/store';
} else {
await startProxy();
}
} catch ({ error }) {
} catch (error) {
return errorNotification(error);
}
}
@@ -92,7 +92,7 @@ import { appSession } from '$lib/store';
const engine = generateRemoteEngine(destination);
await post(`/destinations/${id}/stop.json`, { engine });
return toast.push($t('destination.coolify_proxy_stopped'));
} catch ({ error }) {
} catch (error) {
return errorNotification(error);
}
}
@@ -101,7 +101,7 @@ import { appSession } from '$lib/store';
const engine = generateRemoteEngine(destination);
await post(`/destinations/${id}/start.json`, { engine });
return toast.push($t('destination.coolify_proxy_started'));
} catch ({ error }) {
} catch (error) {
return errorNotification(error);
}
}
@@ -115,7 +115,7 @@ import { appSession } from '$lib/store';
engine: destination.engine,
fqdn: settings.fqdn
});
} catch ({ error }) {
} catch (error) {
setTimeout(() => {
window.location.reload();
}, 5000);