Skip to content

Commit 57158ed

Browse files
authored
Revert #129 (#135)
1 parent 457aa5b commit 57158ed

File tree

1 file changed

+1
-6
lines changed

1 file changed

+1
-6
lines changed

lib/dom/performance/avoidScalingImages.js

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -11,14 +11,9 @@
1111

1212
for (let i = 0, len = images.length; i < len; i++) {
1313
const img = images[i];
14-
const fileExtension = new URL(img.currentSrc).pathname.split('.').pop();
1514

1615
// skip svg images and images that are 0 (carousel etc)
17-
if (
18-
fileExtension !== 'svg' &&
19-
img.clientWidth + minLimit < img.naturalWidth &&
20-
img.clientWidth > 0
21-
) {
16+
if (img.clientWidth + minLimit < img.naturalWidth && img.clientWidth > 0) {
2217
// message = message + ' ' + util.getAbsoluteURL(img.currentSrc) + ' [browserWidth:' + img.clientWidth + ' naturalWidth: ' + img.naturalWidth +']';
2318
offending.push(util.getAbsoluteURL(img.currentSrc));
2419
score += 10;

0 commit comments

Comments
 (0)