Skip to content

Commit

Permalink
Fixed index and show of workers in admin if no photo
Browse files Browse the repository at this point in the history
  • Loading branch information
claire-gtr committed Feb 20, 2020
1 parent 65993c3 commit 6001cf6
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/admin/workers.rb
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
column :name
column :position
column :description
column(:photo) { |w| image_tag(w.photo.url) }
column(:photo) { |w| image_tag(w.photo.url) if w.photo.present? }
actions
end

Expand All @@ -30,7 +30,7 @@
row :name
row :position
row :description
row(:photo) { |w| image_tag(w.photo.url) }
row(:photo) { |w| image_tag(w.photo.url) if w.photo.present? }
end
end
end

0 comments on commit 6001cf6

Please sign in to comment.