From 674d99e1ebcc9b72a3f96a434f08462f2c48c7ce Mon Sep 17 00:00:00 2001 From: gebele Date: Mon, 17 Jun 2013 14:09:38 +0200 Subject: prevent conversion of nil for neighbors --- views/neighbors.haml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/views/neighbors.haml b/views/neighbors.haml index 43fb397..01ffe29 100644 --- a/views/neighbors.haml +++ b/views/neighbors.haml @@ -84,9 +84,9 @@ Details -#%tbody - count = 0 - / prevent conversion of nil - - c = p.data_entries[count][2] != nil ? p.data_entries[count][2] : '' - p.compounds.each do |neighbor_compound| + / prevent conversion of nil + - c = p.data_entries[count][2] != nil ? p.data_entries[count][2] : '' %tr %td.compound %img{:src=>"#{neighbor_compound.uri}/image", :alt=>"", :width=>"100px"} -- cgit v1.2.3