From ed75e56bdeea9be274a9016d58d6bce5f90843c7 Mon Sep 17 00:00:00 2001 From: GreLI Date: Sun, 16 Sep 2018 20:58:12 +0300 Subject: [PATCH] Fix and update cleanupListOfValues tests --- plugins/cleanupListOfValues.js | 2 +- test/plugins/cleanupListOfValues.02.svg | 8 ++++++++ 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/plugins/cleanupListOfValues.js b/plugins/cleanupListOfValues.js index 461a2bcf..e4aa980a 100644 --- a/plugins/cleanupListOfValues.js +++ b/plugins/cleanupListOfValues.js @@ -125,7 +125,7 @@ exports.fn = function(item, params) { // if attribute value is "new"(only enable-background). else if (matchNew) { roundedListArr.push('new'); - } else { + } else if (elem) { roundedListArr.push(elem); } diff --git a/test/plugins/cleanupListOfValues.02.svg b/test/plugins/cleanupListOfValues.02.svg index e16dc90a..27d203aa 100644 --- a/test/plugins/cleanupListOfValues.02.svg +++ b/test/plugins/cleanupListOfValues.02.svg @@ -1,6 +1,10 @@ test + + + + @@@ @@ -8,4 +12,8 @@ test + + + +