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

@truffle/blockchain-utils

Package Overview
Dependencies
Maintainers
5
Versions
59
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@truffle/blockchain-utils - npm Package Compare versions

Comparing version 0.0.26 to 0.0.27

8

dist/index.js

@@ -52,4 +52,4 @@ "use strict";

const parsedUri = this.parse(uri);
const expected_genesis = parsedUri.genesis_hash;
const expected_block = parsedUri.block_hash;
const expectedGenesis = parsedUri.genesis_hash;
const expectedBlock = parsedUri.block_hash;
this.getBlockByNumber("0x0", provider, (err, { result }) => {

@@ -59,5 +59,5 @@ if (err)

const block = result;
if (block.hash !== expected_genesis)
if (block.hash !== expectedGenesis)
return resolve(false);
this.getBlockByHash(expected_block, provider, (err, { result }) => {
this.getBlockByHash(expectedBlock, provider, (err, { result }) => {
// Treat an error as if the block didn't exist. This is because

@@ -64,0 +64,0 @@ // some clients respond differently.

@@ -87,4 +87,4 @@ import "source-map-support/register";

const expected_genesis = parsedUri.genesis_hash;
const expected_block = parsedUri.block_hash;
const expectedGenesis = parsedUri.genesis_hash;
const expectedBlock = parsedUri.block_hash;

@@ -97,6 +97,6 @@ this.getBlockByNumber(

const block = result;
if (block.hash !== expected_genesis) return resolve(false);
if (block.hash !== expectedGenesis) return resolve(false);
this.getBlockByHash(
expected_block,
expectedBlock,
provider,

@@ -103,0 +103,0 @@ (err: Error, { result }: JsonRPCResponse) => {

@@ -11,3 +11,3 @@ {

},
"version": "0.0.26",
"version": "0.0.27",
"main": "dist/index.js",

@@ -40,3 +40,3 @@ "scripts": {

},
"gitHead": "5f8fa364c8a0dbf0e07827035b1c335901549097"
"gitHead": "2079746a5e3773e0023f80d8f95a5651d8be2b93"
}

Sorry, the diff of this file is not supported yet

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