You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
/**
* Move the gallery to a specific index
* @param `index` {number} - the position of the image
* @param `gallery` {array} - gallery which should be opened, if omitted assumes the currently opened one
* @return {boolean} - true on success or false if the index is invalid
*/
function show(index, gallery) {
if (!isOverlayVisible && index >= 0 && index < gallery.length) {
prepareOverlay(gallery, options);
showOverlay(index);
return true;
The comment says that the gallery argument can be omitted. Still, the condition takes gallery.length, which is a TypeError if gallery==undefined. The other show...() functions (from line 603 to 627) all use show() with one argument only.
The text was updated successfully, but these errors were encountered:
Currently the show() function looks like this:
The comment says that the gallery argument can be omitted. Still, the condition takes gallery.length, which is a TypeError if gallery==undefined. The other show...() functions (from line 603 to 627) all use show() with one argument only.
The text was updated successfully, but these errors were encountered: