Socket
Socket
Sign inDemoInstall

dot-prop

Package Overview
Dependencies
Maintainers
1
Versions
29
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

dot-prop - npm Package Compare versions

Comparing version 8.0.1 to 8.0.2

6

index.js

@@ -298,8 +298,8 @@ const isObject = value => {

function entries(value) {
const result = Object.entries(value);
if (Array.isArray(value)) {
// We use `[...value]` to convert sparse entries to normal ones.
return [...value].map((value, index) => [index, value]);
return result.map(([key, value]) => [Number(key), value]);
}
return Object.entries(value);
return result;
}

@@ -306,0 +306,0 @@

{
"name": "dot-prop",
"version": "8.0.1",
"version": "8.0.2",
"description": "Get, set, or delete a property from a nested object using a dot path",

@@ -5,0 +5,0 @@ "license": "MIT",

@@ -138,2 +138,4 @@ # dot-prop

Sparse arrays are supported. In general, [avoid using sparse arrays](https://github.com/sindresorhus/dot-prop/issues/109#issuecomment-1614819869).
#### object

@@ -140,0 +142,0 @@

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc