Skip to content

ServerKit is a lightweight, modern server control panel for managing web applications, databases, and services on your VPS or dedicated server. Built with Python/Flask backend and React frontend.

fix(services): the delete confirmation no longer promises something untrue

Juan Denis6166158b26a6
diff --git a/frontend/src/components/appdetail/SettingsTab.jsx b/frontend/src/components/appdetail/SettingsTab.jsx
index fc220c94..9ed232f5 100644
--- a/frontend/src/components/appdetail/SettingsTab.jsx
+++ b/frontend/src/components/appdetail/SettingsTab.jsx
@@ -29,13 +29,13 @@ const SettingsTab = ({ app, onUpdate }) => {
const jobs = (await api.getCronJobsForApp(app.id))?.jobs || [];
if (jobs.length) {
const names = jobs.map((j) => j.name || 'Unnamed').join(', ');
- cronNote = ` ${jobs.length} scheduled task${jobs.length > 1 ? 's' : ''} will be kept but detached from this app: ${names}.`;
+ cronNote = ` ${jobs.length} scheduled task${jobs.length > 1 ? 's' : ''} will be suspended and resumed if you restore it: ${names}.`;
}
} catch { /* cron visibility is best-effort — never block the delete */ }
- const firstConfirm = await confirmAppSettings({ title: 'Delete Application', message: `Delete ${app.name}? This action cannot be undone.${cronNote}` });
+ const firstConfirm = await confirmAppSettings({ title: 'Delete Application', message: `Delete ${app.name}? It stops serving and moves to the recycle bin, where you can restore it for 30 days.${cronNote}` });
if (!firstConfirm) return;
- const secondConfirm = await confirmAppSettings({ title: 'Confirm Deletion', message: 'Are you sure? This will permanently delete the application and all its data.' });
+ const secondConfirm = await confirmAppSettings({ title: 'Confirm Deletion', message: 'Are you sure? Its containers stop and it stops being served. Files and data volumes are kept until you purge it from the recycle bin.' });
if (!secondConfirm) return;
setDeleting(true);
diff --git a/frontend/src/components/service-detail/SettingsTab.jsx b/frontend/src/components/service-detail/SettingsTab.jsx
index ca10556e..3b3e4ede 100644
--- a/frontend/src/components/service-detail/SettingsTab.jsx
+++ b/frontend/src/components/service-detail/SettingsTab.jsx
@@ -151,13 +151,13 @@ const SettingsTab = ({ app, deployConfig, domains, primaryDomain, onUpdate }) =>
async function handleDelete() {
if (!await confirm({
title: 'Delete Service',
- message: `Delete ${app.name}? This action cannot be undone.`,
+ message: `Delete ${app.name}? It stops serving and moves to the recycle bin, where you can restore it for 30 days.`,
confirmText: 'Delete',
variant: 'danger',
})) return;
if (!await confirm({
title: 'Delete Service',
- message: 'Are you sure? This will permanently remove the service.',
+ message: 'Are you sure? Its containers stop and it stops being served. Files and data volumes are kept until you purge it from the recycle bin.',
confirmText: 'Delete',
variant: 'danger',
})) return;
@@ -165,6 +165,7 @@ const SettingsTab = ({ app, deployConfig, domains, primaryDomain, onUpdate }) =>
setDeleting(true);
try {
await api.deleteApp(app.id);
+ toast.success(`“${app.name}” moved to the recycle bin`);
navigate('/services');
} catch (err) {
toast.error('Failed to delete service');