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

digirati-annotation-bridge

Package Overview
Dependencies
Maintainers
3
Versions
164
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

digirati-annotation-bridge - npm Package Compare versions

Comparing version 0.8.12 to 0.8.13

7

es/annotationBody.js

@@ -54,5 +54,6 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }

if (Object.prototype.toString.call(body) !== '[object Array]') {
return null;
if (Object.prototype.toString.call(body) !== '[object Array]' || body.length === 0) {
return new AnnotationBody();
}
var textualBody = body.filter(function (item) {

@@ -66,3 +67,3 @@ return (item.type ? item.type : '').toLowerCase() === 'textualbody' || (item.type ? item.type : '').toLowerCase() === 'text';

var source = specificResource ? specificResource[0]['source'] : null;
var source = specificResource && specificResource[0] ? specificResource[0]['source'] : null;
var type = source ? tagClassForUri(source) : null;

@@ -69,0 +70,0 @@

@@ -59,5 +59,6 @@ 'use strict';

if (Object.prototype.toString.call(body) !== '[object Array]') {
return null;
if (Object.prototype.toString.call(body) !== '[object Array]' || body.length === 0) {
return new AnnotationBody();
}
var textualBody = body.filter(function (item) {

@@ -71,3 +72,3 @@ return (item.type ? item.type : '').toLowerCase() === 'textualbody' || (item.type ? item.type : '').toLowerCase() === 'text';

var source = specificResource ? specificResource[0]['source'] : null;
var source = specificResource && specificResource[0] ? specificResource[0]['source'] : null;
var type = source ? tagClassForUri(source) : null;

@@ -74,0 +75,0 @@

{
"name": "digirati-annotation-bridge",
"version": "0.8.12",
"version": "0.8.13",
"description": "Describe annotation-bridge here",

@@ -22,3 +22,3 @@ "main": "lib/index.js",

"dependencies": {
"digirati-annotation-redux": "^0.8.12",
"digirati-annotation-redux": "^0.8.13",
"lodash.flatten": "^4.4.0"

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