summaryrefslogtreecommitdiffstats
path: root/xslt
diff options
context:
space:
mode:
authorGravatar Miika Turkia <miika.turkia@gmail.com>2015-11-03 18:12:48 +0200
committerGravatar Dirk Hohndel <dirk@hohndel.org>2015-11-03 08:24:05 -0800
commitaf323a9fb1cafba830f8900538c957871d884cf9 (patch)
tree69f2168e23cf1d9adf03bcf6c4568e8a1b6ef959 /xslt
parent048c5e01b14b2388841993165db26c612f0c3fe4 (diff)
downloadsubsurface-af323a9fb1cafba830f8900538c957871d884cf9.tar.gz
Only include samples with data on UDDF import
According to the specification each proper sample should have depth, so we can just ignore the empty waypoints. Signed-off-by: Miika Turkia <miika.turkia@gmail.com> Signed-off-by: Dirk Hohndel <dirk@hohndel.org>
Diffstat (limited to 'xslt')
-rw-r--r--xslt/uddf.xslt2
1 files changed, 2 insertions, 0 deletions
diff --git a/xslt/uddf.xslt b/xslt/uddf.xslt
index d37bf6795..dddd8bd17 100644
--- a/xslt/uddf.xslt
+++ b/xslt/uddf.xslt
@@ -458,6 +458,7 @@
</xsl:for-each>
<xsl:for-each select="samples/waypoint|u:samples/u:waypoint|u1:samples/u1:waypoint|samples/d">
+ <xsl:if test="./depth|./u:depth|./u1:depth != ''">
<sample>
<xsl:attribute name="time">
<xsl:call-template name="timeConvert">
@@ -558,6 +559,7 @@
</xsl:attribute>
</xsl:if>
</sample>
+ </xsl:if>
</xsl:for-each>
</divecomputer>
</dive>