Skip to content

objectql: HookEntry.dispatchUnscopedMultiWrite doc example ("sys_attachment … declaring it on beforeDelete and not on an update one") goes half-stale once #10091 lands #10172

Description

@os-zhuang

Observation, not a runtime defect. Found while implementing #10091; out of that card's surface (packages/objectql/src/engine.ts).

The HookEntry.dispatchUnscopedMultiWrite doc block (around engine.ts:1360) illustrates the flag's per-registration expressiveness with:

so "delete only" (#4757's sys_attachment guard, which declares no update refusal) is still said exactly — by declaring it on the beforeDelete registration and not on an update one.

Accurate when written (#9974). Once #10091's PR (#10169) merges, sys_attachment declares the flag on both write registrations (the update-verb refusal under #10091, the delete-verb one still under #4757), so the worked example describes a state the tree no longer has. The mechanism documentation itself stays correct — only the example's referent moved. sys_comment already declares on both, so the comment loses its only "delete only" exemplar; the fix is a one-line re-point of the example (either to a hypothetical, or to note the history: "delete only" was said exactly this way until #10091).

Backlinks: #10091 / PR #10169 (what moves it), #9974 (the ruling the comment records), #4757 (the delete refusal it cites).


Generated by Claude Code

Metadata

Metadata

Assignees

No one assigned

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions