Skip to content

Commit 3113795

Browse files
committed
regexp match -> test where we only care about truthiness
1 parent 5ceec1d commit 3113795

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/lib/svg_text_utils.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -391,7 +391,7 @@ function buildSVGText(containerNode, str) {
391391
currentNode = nodeStack[nodeStack.length - 1].node;
392392
}
393393

394-
var hasLines = str.match(BR_TAG);
394+
var hasLines = BR_TAG.test(str);
395395

396396
if(hasLines) newLine();
397397
else {

0 commit comments

Comments
 (0)