diff options
author | Jochen Topf <jochen@topf.org> | 2014-05-16 12:18:47 +0200 |
---|---|---|
committer | Jochen Topf <jochen@topf.org> | 2014-05-16 12:18:47 +0200 |
commit | 82bd3f8db092a67069ce9471737ddf21606d8a92 (patch) | |
tree | 2fa6582736f03c76630a2f1a5a69c1db6d03e692 /web/views | |
parent | 0909954e215283d1ca0e393d109e98c859e7e662 (diff) | |
download | taginfo-82bd3f8db092a67069ce9471737ddf21606d8a92.tar taginfo-82bd3f8db092a67069ce9471737ddf21606d8a92.tar.gz |
Don't show map on key comparison page if there isn't one.
Diffstat (limited to 'web/views')
-rw-r--r-- | web/views/key_comparison.erb | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/web/views/key_comparison.erb b/web/views/key_comparison.erb index 649e4a0..a113c42 100644 --- a/web/views/key_comparison.erb +++ b/web/views/key_comparison.erb @@ -61,10 +61,12 @@ <tr> <% @keys.each_with_index do |key, num| %> <td class="data key<%= num %>"> + <% if @has_map[num] %> <div style="background-image: url(<%= TaginfoConfig.get('geodistribution.background_image') %>); background-repeat: no-repeat; background-position: center 4px; background-size: <%= @img_width %>px <%= @img_height %>px; position: relative;"/> <img class="map" src="/api/4/key/distribution/nodes?key=<%= key %>" alt="" width="<%= @img_width %>" height="<%= @img_height %>" style="position: absolute;"/> <img class="map" src="/api/4/key/distribution/ways?key=<%= key %>" alt="" width="<%= @img_width %>" height="<%= @img_height %>"/> </div> + <% end %> </td> <% end %> </tr> |