Opened 4 years ago

Last modified 4 years ago

#1747 new change

GetElementHidingSelectors should return an empty list if the website is whitelisted by any option

Reported by: sergz Assignee:
Priority: Unknown Milestone:
Module: Unknown Keywords:
Cc: Blocked By: #1711
Blocking: Platform: Unknown
Ready: no Confidential: no
Tester: Verified working:
Review URL(s):



Since this question periodically arises it would be nice to discus it to better understand whether we need it or not and the reasons of the final decision.

Currently the client of libadblockplus and of the core library has to firstly test whether the website is whitelisted or not and only then call GetElementHidingSelectors if necessary.


  • avoiding of the same logic on different clients


  • the current version seems good from the API fatness point of view, there are no auxiliary parameters, merely what we need, there is no additional logic (see Pros) which can limit the usage of it.
  • the current version seems useful to show potentially blockable items, otherwise the API could be overcomplicated with additional flags/parameters
  • for the performance reason we should not call it twice or more for the same website, at the same time we need to know exactly whether the website is whitelisted or not.

Please leave your thoughts.

Change History (1)

comment:1 Changed 4 years ago by fhd

Note that it's not just GetElementHidingSelectors, it's the same with Matches - the logic has to be in the client currently. If we were to change this, we should change it everywhere IMO, everything else seems confusing. But I suppose you're not a fan of that since you only propose it for GetElementHidingSelectors?

Note: See TracTickets for help on using tickets.