New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
bad problem with ObjectId.isValid() #3823
Comments
oh shit, wtf
what is it ok if it's a number? This makes no sense because 5 moments later Mongo will barf saying 95 can't be cast to ObjectId by the database. |
it also throws error can someone update it? |
oh thats nice mongodb/js-bson#160 |
|
It works with strings, but if I try to check if So seems like |
I am having a helluva a time trying to determining if a value is a valid ObjectId, there seems to be a big problem with this -
I tried
take a look here:
you can see that the value "95" or 95 slips through:
filter
map
what the heck is going on?
please help, thanks!
The text was updated successfully, but these errors were encountered: