Socket
Socket
Sign inDemoInstall

rdf-terms

Package Overview
Dependencies
5
Maintainers
1
Versions
21
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 1.7.0 to 1.7.1

CHANGELOG.md

7

lib/TermUtil.js
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.getQuads = exports.getDefaultGraphs = exports.getVariables = exports.getLiterals = exports.getBlankNodes = exports.getNamedNodes = exports.getTermsOfType = exports.uniqTerms = exports.TERM_TYPES = void 0;
const rdf_string_1 = require("rdf-string");
/**

@@ -19,3 +20,7 @@ * All known term types.

function uniqTerms(terms) {
return require('lodash.uniqwith')(terms, (termA, termB) => termA.equals(termB));
const hash = {};
return terms.filter(term => {
const termString = rdf_string_1.termToString(term);
return !(termString in hash) && (hash[termString] = true);
});
}

@@ -22,0 +27,0 @@ exports.uniqTerms = uniqTerms;

8

package.json
{
"name": "rdf-terms",
"version": "1.7.0",
"version": "1.7.1",
"description": "Convenience functions for handling RDFJS terms",

@@ -34,7 +34,7 @@ "keywords": [

"@rdfjs/types": "*",
"lodash.uniqwith": "^4.5.0",
"rdf-data-factory": "^1.1.0"
"rdf-data-factory": "^1.1.0",
"rdf-string": "^1.6.0"
},
"devDependencies": {
"@types/jest": "^26.0.0",
"@types/jest": "^27.0.0",
"coveralls": "^3.0.0",

@@ -41,0 +41,0 @@ "jest": "^26.0.0",

SocketSocket SOC 2 Logo

Product

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc