Skip to content

Commit

Permalink
Add protection if more than one orgName of same type.
Browse files Browse the repository at this point in the history
  • Loading branch information
TomazErjavec committed Mar 26, 2024
1 parent a95c75e commit fd88d7b
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Scripts/parlamint-lib.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -710,6 +710,11 @@
<xsl:param name="full"/>
<xsl:variable name="orgName" select="et:l10n($corpus-language, $org/tei:orgName[@full=$full])"/>
<xsl:choose>
<xsl:when test="$orgName[2]">
<xsl:message select="concat('WARN: organisation ', $org/@xml:id, ' with two orgName/@full = ', $full,
': outputting only the last one!')"/>
<xsl:value-of select="$orgName[last()]"/>
</xsl:when>
<xsl:when test="normalize-space($orgName)">
<xsl:value-of select="$orgName"/>
</xsl:when>
Expand Down

0 comments on commit fd88d7b

Please sign in to comment.