Scriptlets icon indicating copy to clipboard operation
Scriptlets copied to clipboard

Fix scriptlet — `set-constant` don't work on m.iqiyi.com

Open AdamWr opened this issue 4 years ago • 1 comments

Steps to reproduce:

  1. Disable all filters and add this rule: m.iqiyi.com#%#//scriptlet("set-constant", "QiyiPlayerLoader.Package.ad.adPlayerId", "")
  2. Go here - https://m.iqiyi.com/v_2cu39c8o6f8.html Important - check with mobile website version.

It seems that rule doesn't work. Uncaught TypeError: Cannot read property 'ad' of null

Screenshot

image

AdamWr avatar May 24 '21 12:05 AdamWr

for now set-constant scriptlet does not set the chained property if one of chain prop is null. that might happen, for example, while loading the page. after the needed property is loaded, the scriptlet does not check it and do not set the value

there is no fix for it now, we will come back to this issue later

slavaleleka avatar May 27 '21 16:05 slavaleleka