Trim whitespace
parent
d2cfc10cbb
commit
52dd1a87f2
|
@ -98,7 +98,7 @@ const TagInput = React.createClass({
|
|||
handleAddTag(e) {
|
||||
if (e.key === 'Enter') {
|
||||
e.preventDefault();
|
||||
const newItem = e.target.value;
|
||||
const newItem = e.target.value.trim();
|
||||
const {tags, onAddTag} = this.props;
|
||||
if (!this.shouldAddToList(newItem, tags)) {
|
||||
return;
|
||||
|
|
Loading…
Reference in New Issue