diff --git a/app/views/admin/sponsors/index.html.haml b/app/views/admin/sponsors/index.html.haml index 1c8f1077..d2fc512c 100644 --- a/app/views/admin/sponsors/index.html.haml +++ b/app/views/admin/sponsors/index.html.haml @@ -19,7 +19,8 @@ - @conference.sponsors.each do |sponsor| %tr %td - = image_tag(sponsor.picture.thumb.url, width: '20%') + - if sponsor.picture? + = image_tag(sponsor.picture.thumb.url, width: '20%') %td = sponsor.name %td diff --git a/app/views/conferences/_modal_description.haml b/app/views/conferences/_modal_description.haml index eb6f2b69..7fe4173b 100644 --- a/app/views/conferences/_modal_description.haml +++ b/app/views/conferences/_modal_description.haml @@ -15,7 +15,8 @@ - if object.is_a? Sponsor - img_classes << ['img-sponsor', "img-sponsor-#{object.sponsorship_level.position}"] - = image_tag get_logo(object), class: img_classes + - if object.picture? + = image_tag get_logo(object), class: img_classes %p.description = object.description .modal-footer