Skip to content

Fix the verify email user action - #476

Merged
jbrooksuk merged 1 commit into
cachethq:mainfrom
soymgomez:fix-verify-email-action
Oct 2, 2026
Merged

jbrooksuk merged 1 commit into
cachethq:mainfrom
soymgomez:fix-verify-email-action

Conversation

@soymgomez

Copy link
Copy Markdown
Contributor

Summary

  • fix the Verify email action on the users table, which threw a LogicException instead of sending the verification email:

    The action [verify-email] is attempting to access the selected records query from the table, but it is not using [accessSelectedRecords()], so they are not available.

  • the action closure type-hinted an unused Builder $query parameter. Filament resolves a Builder parameter as the selected records query, which a record action does not provide, so evaluating the closure failed before the notification was sent
  • drop the unused parameter (and the now unused Builder import) and give the closure an explicit void return type, matching the neighbouring reset-two-factor action
  • add a regression test that calls the action on an unverified user and asserts the VerifyEmail notification is sent

Validation

  • the new test fails on main with the LogicException above and passes with the fix
  • vendor/bin/pest: 1135 passed (4162 assertions), after composer build
  • vendor/bin/pint --test: passed
  • vendor/bin/phpstan analyse src/Filament/Resources/Users/UserResource.php: no errors

The action closure type-hinted an unused Builder $query parameter. Filament resolves that parameter as the selected records query, which record actions do not provide, so clicking the action threw a LogicException instead of sending the verification email.
@jbrooksuk
jbrooksuk merged commit 543bf82 into cachethq:main Oct 2, 2026
23 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.

2 participants