Skip to content

Commit

Permalink
eliminated extra error messaging
Browse files Browse the repository at this point in the history
  • Loading branch information
emgeier authored Jan 29, 2025
1 parent ba26752 commit 63c705c
Showing 1 changed file with 5 additions and 18 deletions.
23 changes: 5 additions & 18 deletions html-stylesheet.xsl
Original file line number Diff line number Diff line change
Expand Up @@ -473,28 +473,15 @@
<xsl:param name="formats"/>
<xsl:param name="idno"/>
<xsl:message>IDNO: <xsl:value-of select="$idno"/></xsl:message>
<xsl:message>Debugging: The input value of dataPath is '<xsl:value-of select="$dataPath"/>'</xsl:message>

<!-- Normalize the resource path --> -->
<xsl:variable name="dataPath" select="replace($resource-path, '^.*/data/', './data/')"/>
<xsl:variable name="dataPath" select="replace($resource-path, '^.*/data/', './data/')"/>

<!-- Debugging Messages -->
<xsl:message>
Debugging: The normalized value of dataPath is '<xsl:value-of select="$dataPath"/>'.
</xsl:message>
<!-- Normalize the resource path -->
<xsl:variable name="resolvedPath" select="concat($dataPath, substring-after($idno, 'data/'))"/>
<xsl:message>
Debugging: The resolved dataPath for this resource is '<xsl:value-of select="$resolvedPath"/>'.
</xsl:message>
<xsl:message>
Debugging: The normalized value of dataPath is '<xsl:value-of select="$dataPath"/>'.
</xsl:message>


<!-- Verify if the file exists -->
<xsl:if test="doc-available(xs:anyURI($resolvedPath))">
<xsl:message>Debugging: File found at '<xsl:value-of select="$resolvedPath"/>'</xsl:message>
</xsl:if>
<xsl:if test="not(doc-available(xs:anyURI($resolvedPath)))">
<xsl:message>Warning: File not found at '<xsl:value-of select="$resolvedPath"/>'</xsl:message>
</xsl:if>
<xsl:if test="$formats != ''">
<div class="container otherFormats" xmlns="http://www.w3.org/1999/xhtml">
<xsl:for-each select="tokenize($formats,',')">
Expand Down

0 comments on commit 63c705c

Please sign in to comment.