File tree Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Expand file tree Collapse file tree 1 file changed +6
-2
lines changed Original file line number Diff line number Diff line change 11
11
12
12
for ( let i = 0 , len = images . length ; i < len ; i ++ ) {
13
13
const img = images [ i ] ;
14
- const fileExtension = ( new URL ( img . currentSrc ) ) . pathname . split ( '.' ) . pop ( ) ;
14
+ const fileExtension = new URL ( img . currentSrc ) . pathname . split ( '.' ) . pop ( ) ;
15
15
16
16
// skip svg images and images that are 0 (carousel etc)
17
- if ( fileExtension !== 'svg' && img . clientWidth + minLimit < img . naturalWidth && img . clientWidth > 0 ) {
17
+ if (
18
+ fileExtension !== 'svg' &&
19
+ img . clientWidth + minLimit < img . naturalWidth &&
20
+ img . clientWidth > 0
21
+ ) {
18
22
// message = message + ' ' + util.getAbsoluteURL(img.currentSrc) + ' [browserWidth:' + img.clientWidth + ' naturalWidth: ' + img.naturalWidth +']';
19
23
offending . push ( util . getAbsoluteURL ( img . currentSrc ) ) ;
20
24
score += 10 ;
You can’t perform that action at this time.
0 commit comments