<p>In app/helpers/browse_helper.rb:</p>
<pre style='color:#555'>> @@ -61,8 +61,17 @@ def format_key(key)
> def format_value(key, value)
> if wp = wikipedia_link(key, value)
> link_to h(wp[:title]), wp[:url], :title => t('browse.tag_details.wikipedia_link', :page => wp[:title])
> - elsif wdt = wikidata_link(key, value)
> - link_to h(wdt[:title]), wdt[:url], :title => t('browse.tag_details.wikidata_link', :page => wdt[:title])
> + elsif wdt = wikidata_links(key, value)
> + # IMPORTANT: Note that wikidata_links() returns an array of hashes, unlike for example wikipedia_link(),
> + # which just returns one such hash.
> + # Thus we have to iterate over it here.
> + result = ''
> + for item in wdt
> + # adding a link to the result-string
> + result += ';'+link_to(item[:title], item[:url], :title => t('browse.tag_details.wikidata_link', :page => item[:title].strip))
> + end
</pre>
<p>I suspect it would make more sense to use <code>map</code> to build links and then <code>join</code> to merge them into a single string. It would also avoid the need to then remove the extra semicolon.</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br>Reply to this email directly or <a href="https://github.com/openstreetmap/openstreetmap-website/pull/788/files#r15373581">view it on GitHub</a>.<img alt="" height="1" src="https://github.com/notifications/beacon/1419053__eyJzY29wZSI6Ik5ld3NpZXM6QmVhY29uIiwiZXhwaXJlcyI6MTcyMTg1NTkzMSwiZGF0YSI6eyJpZCI6Mzc2ODAyMTl9fQ==--2e739a046fd45d34592f6ae14544871bfd981837.gif" width="1" /></p>