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

blockchain

Package Overview
Dependencies
Maintainers
1
Versions
7
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

blockchain - npm Package Compare versions

Comparing version 1.0.2 to 1.0.3

17

lib/blockchain.js

@@ -35,8 +35,13 @@ var websocket = require('websocket')

onMessage: function(msg) {
if (msg.type != 'utf8') return debug('binary message received');
debug('msg:' + msg.utf8Data);
onMessage: function(packet) {
if (packet.type != 'utf8') return debug('binary message received');
debug('raw packet:' + packet.utf8Data);
var msg = JSON.parse(packet.utf8Data).x;
var addrs = _.pluck(msg.inputs, 'addr').concat(_.pluck(msg.outputs, 'addr'));
debug('msg:' + JSON.stringify(msg, null, 4));
var addrs = _.pluck(msg.inputs, 'addr').concat(_.pluck(msg.out, 'addr'));
debug(addrs.length + ' addresses involved');
_.each(addrs, function(addr) {

@@ -49,2 +54,6 @@ _.each(this.subs[addr], function(fn) {

close: function() {
this.conn && this.conn.close();
},
onClose: function() {

@@ -51,0 +60,0 @@ debug('closed');

{
"name": "blockchain",
"version": "1.0.2",
"version": "1.0.3",
"author": "Andreas Brekken <a@abrkn.com>",

@@ -5,0 +5,0 @@ "description": "node.js module to access the blockchain websocket api",

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