If some rows have the uniqueId as a number and some rows have it as a string, the code would try to convert the id being searched to a number, which would result in a NaN if it was a string. This would then fail to match any rows. The proper fix is to always use the original _id value to convert to the appropriate type for the comparison.
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||
|
||