Skip to content

Commit

Permalink
Merge branch 'google-link-quickfix' of ssh://github.com:/EFForg/Priva…
Browse files Browse the repository at this point in the history
…cyBadger into google-link-quickfix
  • Loading branch information
bcyphers committed Oct 4, 2018
2 parents 105b8fe + 2c1b3df commit 3c82189
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/js/firstparties/google-search.js
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@ let trap_link = "a[onmousedown^='return rwt(this,'], a[ping]";

// Remove excessive attributes and event listeners from link a
function cleanLink(a) {
// remove all attributes from a link except for href
// remove all attributes from a link except for href,
// target (to support "Open each selected result in a new browser window"),
// class and ARIA attributes
for (let i = a.attributes.length - 1; i >= 0; --i) {
const attr = a.attributes[i];
if (attr.name !== 'href' && attr.name !== 'target' &&
Expand Down

0 comments on commit 3c82189

Please sign in to comment.