From 4b1f409774226ee0d7c57fbd274008833d1dcfd4 Mon Sep 17 00:00:00 2001 From: Will Marshall Date: Wed, 28 May 2014 16:19:10 +1000 Subject: [PATCH] Only rendering images that exist{ --- app/views/modals/_product.html.haml | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/app/views/modals/_product.html.haml b/app/views/modals/_product.html.haml index 70137ba987..52a7bc7f1f 100644 --- a/app/views/modals/_product.html.haml +++ b/app/views/modals/_product.html.haml @@ -2,13 +2,11 @@ .row .columns.small-12.large-6 - %img.product-img{"ng-src" => "{{product.master.images[0].large_url}}"} + %img.product-img{"ng-src" => "{{product.master.images[0].large_url}}", "ng-if" => "product.master.images[0]"} .columns.small-12.large-6 %h2 %img{"ng-src" => "{{product.primary_taxon.icon}}"} {{product.name}} %p {{product.description}} - / %pre - / {{ product | json }} %a.close-reveal-modal{"ng-click" => "$close()"} × - \ No newline at end of file +