mirror of
https://github.com/zulip/zulip.git
synced 2025-11-06 23:13:25 +00:00
minor: Avoid code duplication in input_pill.
This commit is contained in:
@@ -235,9 +235,8 @@ exports.create = function (opts) {
|
|||||||
|
|
||||||
// if there is input, grab the input, make a pill from it,
|
// if there is input, grab the input, make a pill from it,
|
||||||
// and append the pill, then clear the input.
|
// and append the pill, then clear the input.
|
||||||
if (funcs.value(e.target).length > 0) {
|
|
||||||
var value = funcs.value(e.target);
|
var value = funcs.value(e.target);
|
||||||
|
if (value.length > 0) {
|
||||||
// append the pill and by proxy create the pill object.
|
// append the pill and by proxy create the pill object.
|
||||||
var ret = funcs.appendPill(value);
|
var ret = funcs.appendPill(value);
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user