Remove code intended for tag trumping but currently useless.

I think at one point I was using full qualnames on the tag objects
in the mmf uls. But now they just show their base name, so this
code is useless. And I don't think I'll reinstate it because tags
have multiple parents now and I don't want to implement all the
lineage checking in the client js. We'll just let the server handle
the slightly less efficient query.
This commit is contained in:
voussoir 2020-04-02 16:56:44 -07:00
parent 00ad82e07c
commit 3cb8f0adcf

View file

@ -381,19 +381,13 @@ function add_searchtag(box, value, inputted_list, li_class)
}
console.log("adding " + value);
var already_have = false;
// We're going to be doing some in-place splicing to remove,
// so make a duplicate for iterating
existing_tags = Array.from(inputted_list);
for (var index = 0; index < existing_tags.length; index += 1)
for (var index = 0; index < inputted_list.length; index += 1)
{
existing_tag = existing_tags[index];
existing_tag = inputted_list[index];
if (existing_tag == value)
{
already_have = true;
}
else if (existing_tag.startsWith(value + ".") || value.startsWith(existing_tag + "."))
{
remove_searchtag(box, existing_tag, inputted_list);
break;
}
}
if (already_have)