Commit 97bd437
committed
Prepend Undo(Like) instead of restructuring Undo(Follow)
Reviewer noted that the chapter 22 Undo handler in the tutorial
read very differently from the chapter 11 baseline because the
Follow body had been wrapped in an if-block to share the listener
with the new Like branch. Restructure the example so the
Undo(Like) branch is prepended ahead of the original
`if (!(object instanceof Follow)) return;` guard, leaving the
Follow body untouched. The new branch `return`s on success so
the guard never fires for Like objects.
Addresses fedify-dev/fedify#731 (comment)
Assisted-by: Claude Code:claude-opus-4-71 parent 0dcc8fe commit 97bd437
1 file changed
Lines changed: 23 additions & 24 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
207 | 207 | | |
208 | 208 | | |
209 | 209 | | |
210 | | - | |
211 | | - | |
212 | | - | |
213 | | - | |
214 | | - | |
215 | | - | |
216 | | - | |
217 | | - | |
218 | | - | |
219 | | - | |
220 | | - | |
221 | | - | |
222 | | - | |
223 | | - | |
224 | | - | |
225 | | - | |
226 | | - | |
227 | | - | |
228 | | - | |
229 | | - | |
230 | | - | |
231 | | - | |
232 | | - | |
233 | | - | |
234 | 210 | | |
235 | 211 | | |
236 | 212 | | |
| |||
259 | 235 | | |
260 | 236 | | |
261 | 237 | | |
| 238 | + | |
262 | 239 | | |
| 240 | + | |
| 241 | + | |
| 242 | + | |
| 243 | + | |
| 244 | + | |
| 245 | + | |
| 246 | + | |
| 247 | + | |
| 248 | + | |
| 249 | + | |
| 250 | + | |
| 251 | + | |
| 252 | + | |
| 253 | + | |
| 254 | + | |
| 255 | + | |
| 256 | + | |
| 257 | + | |
| 258 | + | |
| 259 | + | |
| 260 | + | |
| 261 | + | |
263 | 262 | | |
264 | 263 | | |
265 | 264 | | |
| |||
0 commit comments