Make google-ima a valid injectable scriptlet

Related feedback:
https://www.reddit.com/r/uBlockOrigin/comments/1m4dbk1/ublock_being_detected_on_south_park_studios/
This commit is contained in:
Raymond Hill 2025-07-20 10:53:56 -04:00
parent 23155d81cd
commit 47cbb43a0e
No known key found for this signature in database
GPG key ID: 25E1490B761470C2
2 changed files with 2 additions and 0 deletions

View file

@ -210,6 +210,7 @@ class RedirectEngine {
const entry = this.resources.get(this.aliases.get(name) || name);
if ( entry === undefined ) { return; }
if ( entry.mime.startsWith(mime) === false ) { return; }
if ( entry.data === undefined ) { return; }
return {
js: entry.toContent(),
world: entry.world,

View file

@ -94,6 +94,7 @@ export default new Map([
} ],
[ 'google-ima.js', {
alias: 'google-ima3', /* adguard compatibility */
data: 'text',
} ],
[ 'googlesyndication_adsbygoogle.js', {
alias: [