fix: await draft deletion through the card facade (#405)

Issue: #405
User-Visible: no
This commit is contained in:
Sergey Matyunin
2026-09-01 22:23:57 +03:00
parent e926ea453e
commit b4809a12ff
25 changed files with 240 additions and 155 deletions
+11
View File
@@ -105,6 +105,17 @@ function relocateEditorPatch(patch, cardSource, editorSource) {
// `find` обязан встречаться в файле ровно один раз: патч, который ложится «куда
// попало», проверяет не то, что объявлен проверять. Это контролирует --check.
const MUTANT_DEFINITIONS = [
{
id: 'draft-delete-drops-the-promise',
guard: 'node demo/smoke_free_walls.mjs',
because: 'a delayed confirmation must keep the draft deletion pending all the way to the '
+ 'card facade; dropping the runtime promise makes the smoke inspect stale geometry (#405)',
patches: [{
file: 'src/houseplan-editor-runtime.ts',
find: " if (sel.kind === 'draft') { await this._deleteDraftWhole(); return; }",
replace: " if (sel.kind === 'draft') { void this._deleteDraftWhole(); return; }",
}],
},
{
id: 'smoke-guard-blind-to-tail',
guard: 'node demo/guard/verify-guard.mjs',