Skip to content
This repository was archived by the owner on Oct 2, 2019. It is now read-only.

Commit 445fdd9

Browse files
author
Brian Feister
committed
Merge pull request #447 from ErlendSB/master
Tagging - Trim the selected string item
2 parents 597bb21 + bf9487f commit 445fdd9

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/select.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -404,7 +404,7 @@
404404
// for `item` if it is a detected duplicate
405405
if ( item === undefined ) return;
406406
// create new item on the fly
407-
item = ctrl.tagging.fct !== undefined ? ctrl.tagging.fct(ctrl.search) : item.replace(ctrl.taggingLabel,'');
407+
item = ctrl.tagging.fct !== undefined ? ctrl.tagging.fct(ctrl.search) : item.replace(ctrl.taggingLabel,'').trim();
408408
}
409409
}
410410
// search ctrl.selected for dupes potentially caused by tagging and return early if found

0 commit comments

Comments
 (0)