From ba57109502393ee732ef314b484d6d1b6257daa7 Mon Sep 17 00:00:00 2001 From: Ketan Gupta Date: Sun, 3 Jul 2016 00:37:01 +0530 Subject: [PATCH] Small bug fix --- js/application.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/js/application.js b/js/application.js index 74faaa4..d8eea4b 100644 --- a/js/application.js +++ b/js/application.js @@ -1,6 +1,6 @@ // Your JavaScript $(function() { - $('.img-center-fill').each(function(){ + $('.img-center-fill').load(function(){ var parent = $(this).parent(); var imgClass = (this.width/this.height > parent.width()/parent.height()) ? 'wide' : 'tall'; $(this).addClass(imgClass);