Repository navigation
Commit 28fafd8
committed
fix(spec):
`ActionSchema.undoable`'s `.describe()` said the `patch` names exactly the
fields whose prior values are captured. An `operation: 'update'` action also
writes what its `params` collect, so on any params-carrying action that
sentence describes a strict subset of what the action writes — an Undo built
to it restores part of the change and reports the action as undone.
The executor already captures the union: `executeDeclarativeUpdateAction`
keys `undoData` off `Object.keys(data)`, `data` being the merged write bag
`{ ...patch, ...params }` from `declarativeUpdateWrite`. The doc block ~200
lines above in the same file already said "exactly the fields written". The
sentence was the outlier; this moves it.
`operation` carries exactly one member, `'update'`, so the per-operation
capture rule is a one-row rule and is stated as one.
Claude-Session: https://claude.ai/code/session_01LvwGppdonww4zGLWZo5rho
Co-authored-by: Claude <noreply@anthropic.com>undoable names the written set, not patch alone1 parent 1739f71 commit 28fafd8
1 file changed
Lines changed: 11 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
1307 | 1307 | | |
1308 | 1308 | | |
1309 | 1309 | | |
1310 | | - | |
1311 | | - | |
1312 | | - | |
1313 | | - | |
| 1310 | + | |
| 1311 | + | |
| 1312 | + | |
| 1313 | + | |
| 1314 | + | |
| 1315 | + | |
| 1316 | + | |
| 1317 | + | |
| 1318 | + | |
| 1319 | + | |
| 1320 | + | |
1314 | 1321 | | |
1315 | 1322 | | |
1316 | 1323 | | |
| |||
0 commit comments