Avoid failures caused by calling toLowerCase() on a number.
Signed-off-by: Bill Erickson <berickxx@gmail.com>
Signed-off-by: Galen Charlton <gmc@equinoxOLI.org>
Signed-off-by: Jane Sandberg <js7389@princeton.edu>
// Filter entrylist whose labels substring-match the
// text entered.
return this.entrylist.filter(entry => {
- const label = entry.label || entry.id;
+ const label = String(entry.label) || String(entry.id);
+ if (!label) { return false; }
+
if (this.startsWith) {
return label.toLowerCase().startsWith(term.toLowerCase());
} else {