Opened 3 years ago

Closed 3 years ago

Last modified 3 years ago

#3580 closed defect (fixed)

Adblock Plus fails to initialize (hence doesn't block anything) on Chrome <38

Reported by: sebastian Assignee: sebastian
Priority: P1 Milestone: Adblock-Plus-1.10.1-for-Chrome-Opera-Safari
Module: Platform Keywords:
Cc: Blocked By:
Blocking: Platform: Unknown / Cross platform
Ready: yes Confidential: no
Tester: Scheer Verified working: yes
Review URL(s):

https://codereview.adblockplus.org/29334532

Description

Environment

Chrome 28-37

Observed behaviour

Adblock Plus doesn't block anything. Also following exception shows up in the log of the background page when the extension is loaded:

Uncaught TypeError: Cannot use 'in' operator to search for 'FONT' in undefined background.js:410

That is because chrome.webRequest.ResourceType was first introduced in Chrome 44. However, that code path is only triggered on Chrome <38 and >48 (at least when the default user agent is used). So this bug is only visible for users on Chrome 37 and before.

This regression has been introduced with b4ff744b0583 in the previous release (1.10).

Expected behaviour

The code should handle if chrome.webRequest.ResourceType doesn't exist, that Adblock Plus initializes successfully, and blocks ads as expected.

Change History (6)

comment:1 Changed 3 years ago by sebastian

  • Review URL(s) modified (diff)

comment:2 Changed 3 years ago by sebastian

  • Summary changed from Adblock Plus doesn't initialize (hence doesn't block anything) on Chrome <38 to Adblock Plus fails to initialize (hence doesn't block anything) on Chrome <38

comment:3 Changed 3 years ago by sebastian

  • Milestone set to Adblock-Plus-1.10.1-for-Chrome-Opera-Safari

comment:4 Changed 3 years ago by sebastian

  • Status changed from new to reviewing

comment:5 Changed 3 years ago by sebastian

  • Resolution set to fixed
  • Status changed from reviewing to closed

comment:6 Changed 3 years ago by scheer

  • Tester changed from Unknown to Scheer
  • Verified working set

Done. Adblock plus correctly blocks ads.

Chrome 30, 31, 32, 33, 34, 35, 36, 37
Adblock plus 1.10.0.1537

Note: See TracTickets for help on using tickets.