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

ssb-crut

Package Overview
Dependencies
Maintainers
4
Versions
38
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

ssb-crut - npm Package Compare versions

Comparing version 1.1.0 to 2.0.0

10

index.js

@@ -30,3 +30,3 @@ const Strategy = require('@tangle/strategy')

this.isValidProps = InputValidator('props', this.spec.props.composition)
this.isValidProps = InputValidator('props', this.spec.props._composition)
}

@@ -46,3 +46,3 @@

try {
propsT = this.spec.props.humanToTransform(
propsT = this.spec.props.mapFromInput(
this.spec.props.identity(),

@@ -84,3 +84,3 @@ props

states: tangle.tips
.map(({ key, T }) => ({ key, ...this.spec.props.reify(T) }))
.map(({ key, T }) => ({ key, ...this.spec.props.mapToOutput(T) }))
}

@@ -106,3 +106,3 @@

...this.spec.props.humanToTransform(
...this.spec.props.mapFromInput(
tip.T,

@@ -153,3 +153,3 @@ props

else if (key === 'allowPublic') acc.allowPublic = value
else if (key in props.composition) acc.props[key] = value
else if (key in props._composition) acc.props[key] = value
else if (key in staticProps) acc.staticProps[key] = value

@@ -156,0 +156,0 @@ else acc.unknown[key] = value

const pull = require('pull-stream')
const reduce = require('@tangle/reduce')
const Reduce = require('@tangle/reduce')

@@ -40,3 +40,4 @@ module.exports = function tangleTips (server, spec, id, cb) {

const msgs = [root, ...updates]
const reduction = reduce(msgs, spec.props, {
const reduce = new Reduce(spec.props, {
nodes: msgs,
getBacklinks: m => m.value.content.tangles[spec.tangle].previous,

@@ -52,3 +53,3 @@ getTransformation: spec.getTransformation,

const tips = Object.entries(reduction)
const tips = Object.entries(reduce.state)
.map(([key, T]) => ({ key, T }))

@@ -55,0 +56,0 @@ .sort((A, B) => timestamps[B.key] - timestamps[A.key])

{
"name": "ssb-crut",
"version": "1.1.0",
"version": "2.0.0",
"description": "easy CRUT methods for secure scuttlebutt",

@@ -29,4 +29,4 @@ "main": "index.js",

"dependencies": {
"@tangle/reduce": "^1.0.3",
"@tangle/strategy": "^1.4.1",
"@tangle/reduce": "^3.0.1",
"@tangle/strategy": "^2.0.1",
"is-my-ssb-valid": "^1.1.0",

@@ -38,4 +38,4 @@ "lodash.merge": "^4.6.2",

"devDependencies": {
"@tangle/complex-set": "^1.2.1",
"@tangle/overwrite": "^1.2.0",
"@tangle/complex-set": "^2.0.0",
"@tangle/overwrite": "^2.0.0",
"scuttle-testbot": "^1.5.1",

@@ -45,4 +45,4 @@ "ssb-backlinks": "^2.1.1",

"ssb-recps-guard": "^2.1.0",
"ssb-tribes": "^0.4.1",
"standard": "^16.0.1",
"ssb-tribes": "^1.1.0",
"standard": "^16.0.3",
"tap-spec": "^5.0.0",

@@ -49,0 +49,0 @@ "tape": "^4.13.3"

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