-
Notifications
You must be signed in to change notification settings - Fork 14
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
Node REPL produces false value for obj instanceof Object
#3
Comments
Thanks for the issue report. Could you provide a code snippet which reproduces the issue? |
I've just published v1.3.1 to npm which includes a more robust check for an object, inspired by your code snippet above. Can you check if the issue still exists with this version? |
Your commit doesn't solved this issue, I'm still having false negative errors. I just made a PR that fix it. Is necessary a more robust solution to check for |
Thanks, fixed and published as v1.3.2. |
An
Object
literal passed through Node REPL isn't equal to the module context. That is, anobj
passed though Node REPL produces false into this line of codeobj instanceof Object
. I find out this after 2 hours stuck into this. To know more about see: In REPL, required modules have different Object than command-linePlease, change
obj instanceof Object
totypeof obj === 'object' && obj !== null
. Thanks.The text was updated successfully, but these errors were encountered: