-
Notifications
You must be signed in to change notification settings - Fork 3
Add comprehensive email validation for blocked users #3
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: blocked-email-validation-pre
Are you sure you want to change the base?
Add comprehensive email validation for blocked users #3
Conversation
… many times each email address is blocked, and last time it was blocked. Move email validation out of User model and into EmailValidator. Signup form remembers which email addresses have failed and shows validation error on email field.
PR Compliance Guide 🔍Below is a summary of compliance checks for this PR:
Compliance status legend🟢 - Fully Compliant🟡 - Partial Compliant 🔴 - Not Compliant ⚪ - Requires Further Human Verification 🏷️ - Compliance label |
||||||||||||||||||||||||
PR Code Suggestions ✨Explore these optional code suggestions:
|
|||||||||||||||
User description
PR #3
PR Type
Enhancement, Tests
Description
Implement comprehensive email blocking system with
BlockedEmailmodelExtract email validation logic into reusable
EmailValidatorclassTrack blocked email statistics (match count, last match time)
Return validation errors and form values to frontend for UX improvements
Add client-side rejected emails tracking to prevent resubmission
Diagram Walkthrough
flowchart LR A["User Signup"] --> B["EmailValidator"] B --> C["BlockedEmail Check"] C --> D{Email Blocked?} D -->|Yes| E["Return Errors & Values"] D -->|No| F["Create User"] E --> G["Frontend Tracks Rejected Emails"] G --> H["Show Validation Error"]File Walkthrough
5 files
New model for managing blocked emailsExtracted email validation logic into validatorRefactored email validation to use EmailValidatorReturn validation errors and values in responseTrack rejected emails and prevent resubmission1 files
Database migration for blocked emails table3 files
Comprehensive tests for BlockedEmail modelTests for EmailValidator blocked email logicTest fabricator for BlockedEmail records1 files
Add blocked email error message translation