Skip to content

fix: gate signup/edit actions behind volunteer approval - #185

Merged
hturnbull93 merged 1 commit into
mainfrom
fix/approval-gate-signup-edit
Jul 25, 2026
Merged

fix: gate signup/edit actions behind volunteer approval#185
hturnbull93 merged 1 commit into
mainfrom
fix/approval-gate-signup-edit

Conversation

@hturnbull93

Copy link
Copy Markdown
Collaborator

Summary

  • Non-approved applicants could bypass the approval gate on several write paths: self-claiming an open task via updateTask, editing a project, messaging volunteers, and submitting local group suggestions were only checking auth, not approvalStatus.
  • Added approvedProcedure in server/procedures.ts and applied it to projects.create/update/expressInterest/createTask/reorderTasks/updateTask/assignTask/deleteTask, messages.send, localGroupSuggestions.create.
  • Backend now also rejects admins assigning a project/task/starter-task to a not-yet-approved volunteer (projects.assign, projects.assignTask, starterTasks.assign — the last had no check at all).
  • volunteers.list now excludes unapproved volunteers, which fixes both the assign dropdowns (previously listed unapproved volunteers who'd then fail on submit) and the public volunteer directory.

Test plan

  • npm run check-all (typecheck, lint, format, full e2e suite — 142 passed / 6 skipped)
  • New e2e/tests/21-approval-gate.spec.ts covers: blocked propose/express-interest/self-claim-task/message/local-group-suggestion for unapproved volunteers, blocked admin-assign to unapproved volunteer (project/task/starter-task), and unapproved volunteers excluded from volunteers.list

🤖 Generated with Claude Code

https://claude.ai/code/session_01VQAA85HZaaMjk12sx5xjbZ

Unapproved applicants could self-claim tasks, edit projects, message
volunteers, and submit local group suggestions — only project creation
and expressInterest were gated. Adds approvedProcedure and applies it
across the affected routes, blocks admins from assigning
projects/tasks/starter-tasks to unapproved volunteers, and excludes
unapproved volunteers from volunteers.list (which feeds both assign
dropdowns and the public directory).

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01VQAA85HZaaMjk12sx5xjbZ
@railway-app
railway-app Bot temporarily deployed to PauseAI Catalyse / catalyse-pr-185 July 25, 2026 09:23 Destroyed
@railway-app

railway-app Bot commented Jul 25, 2026

Copy link
Copy Markdown

🚅 Deployed to the catalyse-pr-185 environment in PauseAI Catalyse

Service Status Web Updated (UTC)
web ✅ Success (View Logs) Web Jul 25, 2026 at 9:25 am
1 service not affected by this PR
  • Cron for digest

@hturnbull93
hturnbull93 merged commit 42ef7c3 into main Jul 25, 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