Simplify this already_have now that the other code is gone.
This commit is contained in:
parent
84833832e4
commit
7fc4604025
1 changed files with 1 additions and 10 deletions
|
@ -372,16 +372,7 @@ PARAM_DEFAULTS = {
|
|||
function add_searchtag(ul, value, inputted_list, li_class)
|
||||
{
|
||||
console.log("adding " + value);
|
||||
var already_have = false;
|
||||
for (var index = 0; index < inputted_list.length; index += 1)
|
||||
{
|
||||
existing_tag = inputted_list[index];
|
||||
if (existing_tag == value)
|
||||
{
|
||||
already_have = true;
|
||||
break;
|
||||
}
|
||||
}
|
||||
var already_have = inputted_list.indexOf(value) !== -1;
|
||||
if (already_have)
|
||||
{return;}
|
||||
|
||||
|
|
Loading…
Reference in a new issue