Project

General

Profile

« Previous | Next » 

Revision ed9cc030

Added by koszko almost 2 years ago

restore compatibility with IceCat 60

View differences:

content/main.js
243 243
{
244 244
    doc.addEventListener("beforescriptexecute", prevent_script_execution);
245 245

  
246
    [...doc.all].flatMap(ele => [...ele.attributes].map(attr => [ele, attr]))
247
	.map(([ele, attr]) => [ele, attr.localName])
248
	.filter(([ele, attr]) => /^on/.test(attr) && ele.wrappedJSObject[attr])
249
	.forEach(([ele, attr]) => ele.wrappedJSObject[attr] = null);
246
    for (const elem of doc.querySelectorAll("*")) {
247
	[...elem.attributes].map(attr => attr.localName)
248
	    .filter(attr => /^on/.test(attr) && elem.wrappedJSObject[attr])
249
	    .forEach(attr => elem.wrappedJSObject[attr] = null);
250
    }
250 251
}
251 252

  
252 253
/*

Also available in: Unified diff