Hi,

I noticed that after I enabled Tag external links as "noreferrer" it did not add the noreferrer attribute.
Looking further it turns out a typo in extlink.module causes the noreferrer setting to return null.

It currently says $settings['extNoreferrer'] while it should be $settings['extlink_noreferrer'].

Comments

wmschram created an issue. See original summary.

wmschram’s picture

Issue summary: View changes
wmschram’s picture

Title: Norefferer setting remains false » Typo in extlink.module causes Norefferer not to work.
Issue summary: View changes
wmschram’s picture

Issue tags: -norefferer config setting false
neslee canil pinto’s picture

Status: Active » Closed (cannot reproduce)
wmschram’s picture

Hi Neslee,
Not sure how you're unable to reproduce this.

The issue is that the setting it's looking for does not exist, causing it to return null.
https://git.drupalcode.org/project/extlink/-/blob/8.x-1.x/extlink.module...

It can be seen here in the original commit that the setting should have been extlink_noreferrer and not extNoreferrer, as defined in the same commit. So it will never have worked in the 8.1.x branch.
https://git.drupalcode.org/project/extlink/-/commit/decadb1a7daf71845e62...

Checking Tag external links as "noreferrer" will not work and will only add 'noopener' and not 'noopener noreferrer'.
I have already checked localy on my own machine by changing it to 'extlink_noreferrer' at that point it works. It's a valid bug.

wmschram’s picture

Status: Closed (cannot reproduce) » Active

Reopened based on previous comment.

sahana _n’s picture

Status: Active » Needs review
StatusFileSize
new1.12 KB

Please review the patch.

Status: Needs review » Needs work
wmschram’s picture

The patch fixes the issue.

neslee canil pinto’s picture

Tests are failing, needs to fix the tests.

oknate’s picture

Status: Needs work » Needs review
StatusFileSize
new3.23 KB

This will fix the tests. The issue is that extlink_noreferrer: true by default, so rel will contain 'noreferrer' on top of 'follow' or 'unfollow', unless turned off.

  • Neslee Canil Pinto committed f63bbe7 on 8.x-1.x
    Issue #3134691 by Sahana _N, oknate, Neslee Canil Pinto: Typo in extlink...
neslee canil pinto’s picture

Status: Needs review » Fixed

Status: Fixed » Closed (fixed)

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