Problem/Motivation

When entering an email address with a mailto: prefix e.g mailto:drupal@example.com the email matcher doesn't see this as a valid email address.

Proposed resolution

In EmailMatcher, strip the mailto: prefix and check if the email address is valid.

CommentFileSizeAuthor
#2 3223914-2.patch2.55 KBjeroent

Comments

JeroenT created an issue. See original summary.

jeroent’s picture

Status: Active » Needs review
Related issues: +#2712951: Linkit for Link field
StatusFileSize
new2.55 KB

Added the code from #2712951: Linkit for Link field and added a kernel test for the email matcher.

Status: Needs review » Needs work

The last submitted patch, 2: 3223914-2.patch, failed testing. View results

jeroent’s picture

Status: Needs work » Needs review
solideogloria’s picture

Version: 8.x-5.x-dev » 6.0.x-dev
Status: Needs review » Reviewed & tested by the community

The patch applies cleanly and works on 6.0.0-beta4.

The test errors above are for PHP 7.0, since return types aren't supported in that version. Since only PHP 7.4+ is supported, this isn't a problem. I think this is a great addition.

solideogloria’s picture

Version: 6.0.x-dev » 6.1.x-dev

  • mark_fullmer committed e79b341b on 6.1.x
    Issue #3223914 by JeroenT, solideogloria: Add email address prefixed...
mark_fullmer’s picture

Status: Reviewed & tested by the community » Fixed

Agreed! This makes good sense. Thanks so much for the contribution! Added to the 6.1.x branch, which is compatible with Drupal 10.1+

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.