Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 5 additions & 1 deletion nx/blocks/snapshot-admin/utils/utils.js
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,11 @@ export async function deleteSnapshot(name, paths = ['/*']) {
}));
const firstError = results.find((result) => result.error);
if (firstError) return firstError;
return results[0];
// once all resources are deleted, delete the snapshot as well
const opts = { method: 'DELETE' };
const resp = await daFetch(`${AEM_ORIGIN}/snapshot/${org}/${site}/main/${name}`, opts);
if (!resp.ok) return formatError(resp);
return { success: true };
}

export function setOrgSite(suppliedOrg, suppliedSite) {
Expand Down