Fix condition for medium PAZ-929 saga again
authorAdam Dickmeiss <adam@indexdata.dk>
Wed, 30 Apr 2014 08:40:57 +0000 (10:40 +0200)
committerAdam Dickmeiss <adam@indexdata.dk>
Wed, 30 Apr 2014 08:40:57 +0000 (10:40 +0200)
etc/xsl/solr-pz2.xsl

index f6fa5dd..5a11a53 100644 (file)
   </xsl:template>
 
   <xsl:template name="string">
-      <pz:metadata>
-       <xsl:attribute  name="type">
-         <xsl:value-of select="../@name"/>
-       </xsl:attribute>
-       <xsl:choose>
-         <xsl:when test="../@name = 'medium' and string-length($medium) = 0">
-         </xsl:when>
-         <xsl:otherwise>
-           <xsl:value-of select="."/>
-         </xsl:otherwise>
-       </xsl:choose>
-      </pz:metadata>
+    <xsl:choose>
+      <xsl:when test="../@name = 'medium' and string-length($medium) &gt; 0">
+      </xsl:when>
+      <xsl:otherwise>
+       <pz:metadata>
+         <xsl:attribute  name="type">
+           <xsl:value-of select="../@name"/>
+         </xsl:attribute>
+         <xsl:value-of select="."/>
+       </pz:metadata>
+      </xsl:otherwise>
+    </xsl:choose>
   </xsl:template>
 
 </xsl:stylesheet>