SQLite null prototype
Hi,
SQLite returns [Object: null prototype] as it's not an object. What is the ideal way of dealing with this?
4 Replies
An object with its prototype set to
null
is still an object. Setting the prototype to null is a common pattern in runtimes to prevent badly written polyfills from messing with return values of functions. Because the prototype is terminated, there is no fallback lookup into the global Object
when a property doesn't exist.
What is the ideal way of dealing with this?Just continue using it as you normally would. If you're running into any problems, please share
Thank you for the answer! I've not encountered any problems so far.
However after upgrading to 2.3 I've begun to see a red squilly line under my node:sqlite import:
npm package "@types/node" is not installed or doesn't exist. (deno not-installed-npm)
All attempts to download @types/node, reseting cache, etc has not made it disapear.
Yes, I'll file an issue after work today or this weekend. Thanks for quick reply!