fix: use `hasOwnProperty` for key existence check
resolves #282
Codecov Report
All modified and coverable lines are covered by tests :white_check_mark:
Project coverage is 97.60%. Comparing base (
d283cf5) to head (0457caf). Report is 80 commits behind head on main.
Additional details and impacted files
@@ Coverage Diff @@
## main #286 +/- ##
==========================================
+ Coverage 95.27% 97.60% +2.33%
==========================================
Files 7 7
Lines 867 711 -156
Branches 187 240 +53
==========================================
- Hits 826 694 -132
+ Misses 41 17 -24
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
:rocket: New features to boost your workflow:
- :snowflake: Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
- :package: JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.
We need to use an object with null proto.
We need to use an object with null proto.
@pi0 This object will be returned for the user to use, and they may expect it to behave like a normal object with prototype functions (e.g., calling .toString() for their own purposes). A "null proto" would break their code.
If this object is only for internal use, that's fine since we control how it's used. But if it's exposed to users, are you still okay with that? 🤔
It wouldn't break user expectations, and using null proto objects is pretty standard way to help this issue.
Thanks 🙏🏼