summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/gallery.common.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/lib/gallery.common.js b/lib/gallery.common.js
index 697a33cb..b499a2cd 100644
--- a/lib/gallery.common.js
+++ b/lib/gallery.common.js
@@ -33,6 +33,7 @@
var elh = $(el).height();
var ph = $(this).height();
var nh = (ph - elh) / 2;
+ if (nh < 1) { var nh = 0; }
$(el).css('margin-top', nh);
});
};