summaryrefslogtreecommitdiffstats
path: root/xslt
diff options
context:
space:
mode:
authorGravatar Miika Turkia <miika.turkia@gmail.com>2017-03-30 07:03:46 +0300
committerGravatar Dirk Hohndel <dirk@hohndel.org>2017-04-01 08:06:09 -0700
commit0a84c6e6934bda991a68c42952320977ceaebf78 (patch)
tree7f6be353a70f861e6d75f26d8cb7f7354cf92909 /xslt
parent2b2df88e87e1672c81fa57e27790d7d7306eacec (diff)
downloadsubsurface-0a84c6e6934bda991a68c42952320977ceaebf78.tar.gz
CSV import: return value only if it exists
If the last two fields were empty, we returned the field separator as next to last value. Now we make sure not to return field separator as field value. Signed-off-by: Miika Turkia <miika.turkia@gmail.com>
Diffstat (limited to 'xslt')
-rw-r--r--xslt/commonTemplates.xsl2
1 files changed, 1 insertions, 1 deletions
diff --git a/xslt/commonTemplates.xsl b/xslt/commonTemplates.xsl
index 5616bb3d4..9f0423a11 100644
--- a/xslt/commonTemplates.xsl
+++ b/xslt/commonTemplates.xsl
@@ -259,7 +259,7 @@
<xsl:value-of select="substring-before($line,$fs)"/>
</xsl:when>
<xsl:otherwise>
- <xsl:if test="substring-after($line, $fs) = ''">
+ <xsl:if test="substring-after($line, $fs) = '' and $line != $fs">
<xsl:value-of select="$line"/>
</xsl:if>
</xsl:otherwise>