Use null instead of undefined here
This commit is contained in:
parent
b76a3d3592
commit
ca04ce3645
1 changed files with 2 additions and 2 deletions
|
@ -859,7 +859,7 @@ function defocusSearchBar() {
|
||||||
for (x = 0; x < vlength; ++x) {
|
for (x = 0; x < vlength; ++x) {
|
||||||
var lev = MAX_LEV_DISTANCE + 1;
|
var lev = MAX_LEV_DISTANCE + 1;
|
||||||
var firstGeneric = getObjectNameFromId(val.generics[x]);
|
var firstGeneric = getObjectNameFromId(val.generics[x]);
|
||||||
var match = undefined;
|
var match = null;
|
||||||
if (elems[firstGeneric]) {
|
if (elems[firstGeneric]) {
|
||||||
match = firstGeneric;
|
match = firstGeneric;
|
||||||
lev = 0;
|
lev = 0;
|
||||||
|
@ -872,7 +872,7 @@ function defocusSearchBar() {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (match !== undefined) {
|
if (match !== null) {
|
||||||
elems[match] -= 1;
|
elems[match] -= 1;
|
||||||
if (elems[match] == 0) {
|
if (elems[match] == 0) {
|
||||||
delete elems[match];
|
delete elems[match];
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue