1
0
mirror of https://github.com/gorhill/uBlock.git synced 2024-07-05 11:37:01 +02:00

Fix spurious warning

Related issue:
- https://github.com/uBlockOrigin/uBlock-issues/issues/2243
This commit is contained in:
Raymond Hill 2022-10-05 07:28:01 -04:00
parent 4ec2e07feb
commit 0bfffb80c4
No known key found for this signature in database
GPG Key ID: 25E1490B761470C2

View File

@ -22,6 +22,8 @@
// For background page
/* globals browser */
'use strict';
/******************************************************************************/
@ -721,7 +723,8 @@ vAPI.setIcon = (( ) => {
for ( const img of imgs ) {
if ( img.r.complete === false ) { return; }
}
const ctx = document.createElement('canvas').getContext('2d');
const ctx = document.createElement('canvas')
.getContext('2d', { willReadFrequently: true });
const iconData = [ null, null ];
for ( const img of imgs ) {
if ( img.cached ) { continue; }