[PATCH 4/5] Improve testing whether we have temp and depth info

Miika Turkia miika.turkia at gmail.com
Thu Jan 22 01:33:12 PST 2015


Signed-off-by: Miika Turkia <miika.turkia at gmail.com>
---
 xslt/xml2manualcsv.xslt | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/xslt/xml2manualcsv.xslt b/xslt/xml2manualcsv.xslt
index 452da66..d766c78 100644
--- a/xslt/xml2manualcsv.xslt
+++ b/xslt/xml2manualcsv.xslt
@@ -32,7 +32,7 @@
     <xsl:value-of select="@duration"/>
     <xsl:text>"</xsl:text>
     <xsl:choose>
-      <xsl:when test="divecomputer[1]/depth != ''">
+      <xsl:when test="divecomputer[1]/depth/@mean|divecomputer[1]/depth/@max != ''">
         <xsl:apply-templates select="divecomputer[1]/depth"/>
       </xsl:when>
       <xsl:otherwise>
@@ -46,7 +46,7 @@
       <xsl:when test="divetemperature/@air|divetemperature/@water != ''">
         <xsl:apply-templates select="divetemperature"/>
       </xsl:when>
-      <xsl:when test="divecomputer[1]/temperature != ''">
+      <xsl:when test="divecomputer[1]/temperature/@air|divecomputer[1]/temperature/@water != ''">
         <xsl:apply-templates select="divecomputer[1]/temperature"/>
       </xsl:when>
       <xsl:otherwise>
-- 
1.9.1



More information about the subsurface mailing list