Skip to content

Fix #2504: correct allow_underscores default to true in isEmail docs#2746

Open
Ayushmann13479 wants to merge 1 commit into
validatorjs:masterfrom
Ayushmann13479:patch-1
Open

Fix #2504: correct allow_underscores default to true in isEmail docs#2746
Ayushmann13479 wants to merge 1 commit into
validatorjs:masterfrom
Ayushmann13479:patch-1

Conversation

@Ayushmann13479

Copy link
Copy Markdown

Fixes #2504

The README incorrectly states allow_underscores defaults to false in isEmail() options, but the actual behavior allows underscores by default (e.g. foo_bar@gmail.com returns true).

Changes:

  • Corrected allow_underscores default value from false to true in the options defaults
  • Added description sentence explaining what allow_underscores: false does

Checklist

  • PR contains only changes related; no stray files, etc.
  • README updated (where applicable)
  • Tests written (where applicable)
  • References provided in PR (where applicable)

…Email docs

Modify isEmail options to include allow_underscores
Updated the isEmail function options to allow underscores.
@codecov

codecov Bot commented Jun 10, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 100.00%. Comparing base (7fdc788) to head (59e497f).

Additional details and impacted files
@@            Coverage Diff            @@
##            master     #2746   +/-   ##
=========================================
  Coverage   100.00%   100.00%           
=========================================
  Files          114       114           
  Lines         2587      2587           
  Branches       656       656           
=========================================
  Hits          2587      2587           

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

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.

Bug: isEmail docs/source suggest allow_underscores is defaulted to false however foo_bar@gmail.com is valid by default

1 participant