<p></p>
<p dir="auto">Due to the way that we process semicolons as delineators for multiple values, we currently discard trailing semicolons. This isn't intentional.</p>
<p dir="auto">The value of every tag shown is processed to some extent, the value <code class="notranslate">|white;</code> is handled here:</p>
<p dir="auto"><a href="https://github.com/openstreetmap/openstreetmap-website/blob/933292167a42ffbd51d5054f640e33620456161d/app/helpers/browse_tags_helper.rb#L39">https://github.com/openstreetmap/openstreetmap-website/blob/933292167a42ffbd51d5054f640e33620456161d/app/helpers/browse_tags_helper.rb#L39</a></p>
<p dir="auto">In Ruby, String#split discards any trailing null values, but this can be overridden by a passing a negative limit (i.e. to return all parts).</p>
<div class="highlight highlight-source-ruby" dir="auto"><pre class="notranslate"><span class="pl-en">irb</span><span class="pl-kos">(</span><span class="pl-en">main</span><span class="pl-kos">)</span>:<span class="pl-c1">006</span><span class="pl-pds">:0</span>> <span class="pl-s">"|white;"</span><span class="pl-kos">.</span><span class="pl-en">split</span><span class="pl-kos">(</span><span class="pl-s">";"</span><span class="pl-kos">)</span>
<span class="pl-c1">=></span> <span class="pl-kos">[</span><span class="pl-s">"white"</span><span class="pl-kos">]</span>
<span class="pl-en">irb</span><span class="pl-kos">(</span><span class="pl-en">main</span><span class="pl-kos">)</span>:<span class="pl-c1">007</span><span class="pl-pds">:0</span>> <span class="pl-s">"|white;"</span><span class="pl-kos">.</span><span class="pl-en">split</span><span class="pl-kos">(</span><span class="pl-s">";"</span><span class="pl-kos">,</span> -<span class="pl-c1">1</span><span class="pl-kos">)</span>
<span class="pl-c1">=></span> <span class="pl-kos">[</span><span class="pl-s">"white"</span><span class="pl-kos">,</span> <span class="pl-s">""</span><span class="pl-kos">]</span></pre></div>
<p dir="auto">To fix this, that line needs changing, and some tests need writing to cover this example too.</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/issues/4036#issuecomment-1554749788">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLJ45JRLX4CW6PZV3RTXG6GARANCNFSM6AAAAAAYH4IYFU">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AAK2OLO2A3MHBEQRADTEZYTXG6GARA5CNFSM6AAAAAAYH4IYFWWGG33NNVSW45C7OR4XAZNMJFZXG5LFINXW23LFNZ2KUY3PNVWWK3TUL5UWJTS4VOMVY.gif" height="1" width="1" alt="" /><span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><openstreetmap/openstreetmap-website/issues/4036/1554749788</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/issues/4036#issuecomment-1554749788",
"url": "https://github.com/openstreetmap/openstreetmap-website/issues/4036#issuecomment-1554749788",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>