Skip to content

Commit 158ff90

Browse files
committed
Improved media type filter
1 parent 38a23cf commit 158ff90

2 files changed

Lines changed: 17 additions & 9 deletions

File tree

js/jquery.lbt-lightbox.js

Lines changed: 15 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/*!
2-
* LBT Lightbox v1.0.7
2+
* LBT Lightbox v1.0.9
33
* by Jean Kássio
44
*
55
* More info:
@@ -328,10 +328,14 @@
328328
GetIframeVideos();
329329
GetHTML5Videos();
330330

331-
$lbt_images = $(options.custom_children, options.container_images);
332-
$totalImages = $lbt_images.length;
333-
334-
LoadImages($lbt_images);
331+
setTimeout(function(){
332+
333+
$lbt_images = $(options.custom_children, options.container_images);
334+
$totalImages = $lbt_images.length;
335+
336+
LoadImages($lbt_images);
337+
338+
}, 500);
335339

336340
}
337341

@@ -1143,9 +1147,13 @@
11431147

11441148
$(imgs).each(function(i){
11451149

1146-
if($(this).attr('src').match('^blob:https?:\/\/(?:www\.)?') == null){
1150+
if(typeof $(this).attr('src') !== 'undefined'){
11471151

1148-
ImageTob64(this);
1152+
if($(this).attr('src').match('^blob:https?:\/\/(?:www\.)?') == null){
1153+
1154+
ImageTob64(this);
1155+
1156+
}
11491157

11501158
}
11511159

0 commit comments

Comments
 (0)