Skip to content

Commit

Permalink
fix(popout): fix some thumbnails not showing up
Browse files Browse the repository at this point in the history
  • Loading branch information
fent committed Nov 14, 2018
1 parent eb19d87 commit 2b66839
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion popup/lazyload.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@

const loadImage = ($img, fn) => {
const img = new Image();
const src = $img.getAttribute('data-src');
let src = $img.getAttribute('data-src');
if (/^\/\//.test(src)) {
src = 'https:' + src;
}
img.onload = () => {
$img.src = src;
$img.classList.remove('lazy');
Expand Down

0 comments on commit 2b66839

Please sign in to comment.