Skip to content

to main#242

Merged
JoshuaVSherman merged 3 commits into
mainfrom
dev
Jul 12, 2026
Merged

to main#242
JoshuaVSherman merged 3 commits into
mainfrom
dev

Conversation

@JoshuaVSherman

Copy link
Copy Markdown
Contributor

No description provided.

JoshuaVSherman and others added 3 commits July 12, 2026 05:38
Root cause: mongoose 9.x removed findByIdAndRemove entirely (Model and
Query), but lib/facade.ts still called it — every deleteById threw
synchronously. handleImage() swallowed that (and any other) rejection
and returned the message string instead of rethrowing, so removeImage's
own catch never fired: no socketError was ever sent, and a bogus
imageDeleted got published with the error text as its payload. Delete
looked like a no-op from the client.

- facade.ts: findByIdAndRemove() now calls the model's findByIdAndDelete
  (mongoose 9.x-compatible), keeping its own external method name so
  Controller/GigController/JamPicsController are untouched.
- AgController.handleImage(): rethrows on failure instead of swallowing,
  so newImage/removeImage's existing catch blocks (which already
  transmit socketError) actually get exercised, and a fake
  imageCreated/imageDeleted no longer gets published on failure.

See WebJamApps/JaMmusic#1199.

Bumps 3.0.7 -> 3.0.8.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Update mongoose dependency from ^9.6.1 to ^9.7.4 and refresh lockfile.

Co-Authored-By: Claude Haiku 4.5 <noreply@anthropic.com>
…e-error

Fix jamPics/gig deletes silently no-oping (root cause of JaMmusic#1199)
@JoshuaVSherman
JoshuaVSherman merged commit 5a5e816 into main Jul 12, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant