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

modelld

Package Overview
Dependencies
Maintainers
1
Versions
16
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

modelld - npm Package Compare versions

Comparing version 0.3.0 to 0.4.0

8

lib/model.js

@@ -245,6 +245,8 @@ 'use strict';

} else {
// TODO: extract error type
// TODO: list which patches failed
var err = Error('Not all patches succeeded');
var err = new Error('Not all patches succeeded');
err.model = updatedModel;
err.diffMap = diffMap;
err.failedURIs = new Set(urisToPatch.filter(function (uri) {
return !patchedURIs.has(uri);
}));
throw err;

@@ -251,0 +253,0 @@ }

{
"name": "modelld",
"version": "0.3.0",
"version": "0.4.0",
"description": "A JavaScript API for selecting and manipulating linked data subgraphs",

@@ -5,0 +5,0 @@ "main": "lib/index.js",

@@ -94,4 +94,5 @@ # modelld

// Update a field's value
const name = profile.get('name')[0]
profile
.set('name', {value: 'Daniel'})
.set(name, {value: 'Daniel'})
.get('name') => [Field('Daniel')]

@@ -101,4 +102,5 @@

// (Assume 'web' is the LDP web client, currently assumed to be https://github.com/solid/solid-web-client)
const name = profile.get('name')[0]
profile
.set('name', {value: 'Daniel'})
.set(name, {value: 'Daniel'})
.add('phone', phone('tel:123-456-7890'))

@@ -110,2 +112,7 @@ .save(rdf, web)

})
.catch(err => {
// err.model is the model including all the updates which worked
// err.diffMap describes the RDF statements which should have been inserted and removed from the server
// err.failedURIs describes the URIs for which the PATCH requests failed
})
```

@@ -112,0 +119,0 @@

Sorry, the diff of this file is too big to display

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