Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

mdast-util-definitions

Package Overview
Dependencies
Maintainers
1
Versions
20
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

mdast-util-definitions - npm Package Compare versions

Comparing version 1.2.1 to 1.2.2

7

index.js
'use strict';
var visit = require('unist-util-visit');
var has = require('has');
module.exports = getDefinitionFactory;
var own = {}.hasOwnProperty;
/* Get a definition in `node` by `identifier`. */

@@ -27,3 +28,3 @@ function getDefinitionFactory(node, options) {

var id = normalise(definition.identifier);
if (!has(cache, id)) {
if (!own.call(cache, id)) {
cache[id] = definition;

@@ -45,3 +46,3 @@ }

var id = identifier && normalise(identifier);
return id && has(cache, id) ? cache[id] : null;
return id && own.call(cache, id) ? cache[id] : null;
}

@@ -48,0 +49,0 @@ }

{
"name": "mdast-util-definitions",
"version": "1.2.1",
"version": "1.2.2",
"description": "Find definition nodes in mdast nodes",

@@ -16,3 +16,2 @@ "license": "MIT",

"dependencies": {
"has": "^1.0.1",
"unist-util-visit": "^1.0.0"

@@ -19,0 +18,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