Repository navigation
Conversation
|
@deanrie is attempting to deploy a commit to the Anysphere Team on Vercel. A member of the Team first needs to authorize it. |
This was referenced Oct 8, 2026
Author
|
Superseded by #449, which carries this commit together with the other plugin-page fix as one reviewable PR. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
deletePluginActionruns.delete().eq("id", id).eq("owner_id", userId)through the user-scoped Supabase client and only checkserror. PostgREST does not treat a delete that matches zero rows as an error, so when the row survives (RLS refusing the delete, or any other reason the filter matches nothing), the action still returns success, the UI shows "Plugin deleted." and navigates home, and the listing stays live with its slug and repository URL. That is the sequence in #413, #429 and #438, and #429 already points at this code.This adds
.select("id")to the delete and throws anActionErrorwhen nothing came back, so the owner sees a real error toast instead of a false success. It does not change which rows the policy allows to be deleted; the stuck listings in those issues still need the backend cleanup, this just stops the UI from lying about it.togglePluginListingActionalready has the equivalent guard through.select("slug").single(), so unpublish is not touched.Fixes #413, fixes #429, fixes #438.
Verification
bun x biome ci .andbun run typecheck(apps/cursor) pass, same commands asci.yml.handleServerError(ActionErroris passed through) andplugin-owner-menu.tsxalready renderserror.serverErrorin theonErrortoast.