#47793 closed defect (bug) (fixed)
Incorrect filter documentation in is_email() function
Reported by: | jenkoian | Owned by: | SergeyBiryukov |
---|---|---|---|
Milestone: | 5.3 | Priority: | normal |
Severity: | normal | Version: | 5.3 |
Component: | Formatting | Keywords: | has-patch |
Focuses: | docs | Cc: |
Description
The docs for the is_email()
filter are slightly incorrect:
/** * Filters whether an email address is valid. * * This filter is evaluated under several different contexts, such as 'email_too_short', * 'email_no_at', 'local_invalid_chars', 'domain_period_sequence', 'domain_period_limits', * 'domain_no_periods', 'sub_hyphen_limits', 'sub_invalid_chars', or no specific context. * * @since 2.8.0 * * @param bool $is_email Whether the email address has passed the is_email() checks. Default false. * @param string $email The email address being checked. * @param string $context Context under which the email was tested. */
Suggests that $is_email
will always be a boolean, but as you can see from the following it could be a string:
return apply_filters( 'is_email', $email, $email, null );
Attachments (1)
Change History (3)
Note: See
TracTickets for help on using
tickets.
In 45703: