Skip to content

WAIT: Stop flagging a "Facilitator" form title as differing from a facilitator affiliation#1874

Draft
maebeale wants to merge 1 commit into
mainfrom
maebeale/moscow-v2
Draft

WAIT: Stop flagging a "Facilitator" form title as differing from a facilitator affiliation#1874
maebeale wants to merge 1 commit into
mainfrom
maebeale/moscow-v2

Conversation

@maebeale

Copy link
Copy Markdown
Collaborator

🤖 PR, suggested 👤 review level: 📖 Read — light-logic: a one-line condition change with a covering test

What is the goal of this PR and why is this important?

The "Title differs from form" badge on the org-affiliations panel was firing even when the title matched. A form whose Position/title is literally "Facilitator" was flagged as differing from an org's existing facilitator affiliation, which is wrong and confusing for admins reviewing registrations.

How did you approach the change?

The comparison previously excluded facilitator affiliations (role_affiliations) before checking for a match, so a facilitator-only org always looked mismatched. Now the submitted position is compared against all affiliations — a facilitator affiliation's title is already "Facilitator", so it matches correctly via casecmp?. Added a request spec covering the facilitator/"Facilitator" match case (written failing-first).

UI Testing Checklist

  • Submit a registration with Position/title "Facilitator" for an org that has a facilitator affiliation → no "Title differs from form" badge
  • Submit a position that genuinely differs (e.g. "Director" vs "Counselor") → badge still shows

Anything else to add?

No data or schema changes.

…tor affiliation

The title-comparison badge excluded facilitator affiliations from the
match check, so a form whose position is literally "Facilitator" was
flagged as differing even when the org already had a matching facilitator
affiliation. Compare against all affiliations instead.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
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