Socket
Socket
Sign inDemoInstall

@cosmjs/tendermint-rpc

Package Overview
Dependencies
Maintainers
2
Versions
105
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@cosmjs/tendermint-rpc - npm Package Compare versions

Comparing version 0.32.0 to 0.32.1

12

build/comet38/adaptor/responses.js

@@ -209,12 +209,2 @@ "use strict";

}
/**
* In some cases a timestamp is optional and set to the value 0 in Go.
* This can lead to strings like "0001-01-01T00:00:00Z" (see https://github.com/cosmos/cosmjs/issues/704#issuecomment-797122415).
* This decoder tries to clean up such encoding from the API and turn them
* into undefined values.
*/
function decodeOptionalTime(timestamp) {
const nonZeroTime = timestamp && !timestamp.startsWith("0001-01-01");
return nonZeroTime ? (0, dates_1.fromRfc3339WithNanoseconds)(timestamp) : undefined;
}
function decodeCommitSignature(data) {

@@ -224,3 +214,3 @@ return {

validatorAddress: data.validator_address ? (0, encoding_1.fromHex)(data.validator_address) : undefined,
timestamp: decodeOptionalTime(data.timestamp),
timestamp: data.timestamp ? (0, dates_1.fromRfc3339WithNanoseconds)(data.timestamp) : undefined,
signature: data.signature ? (0, encoding_1.fromBase64)(data.signature) : undefined,

@@ -227,0 +217,0 @@ };

@@ -207,12 +207,2 @@ "use strict";

}
/**
* In some cases a timestamp is optional and set to the value 0 in Go.
* This can lead to strings like "0001-01-01T00:00:00Z" (see https://github.com/cosmos/cosmjs/issues/704#issuecomment-797122415).
* This decoder tries to clean up such encoding from the API and turn them
* into undefined values.
*/
function decodeOptionalTime(timestamp) {
const nonZeroTime = timestamp && !timestamp.startsWith("0001-01-01");
return nonZeroTime ? (0, dates_1.fromRfc3339WithNanoseconds)(timestamp) : undefined;
}
function decodeCommitSignature(data) {

@@ -222,3 +212,3 @@ return {

validatorAddress: data.validator_address ? (0, encoding_1.fromHex)(data.validator_address) : undefined,
timestamp: decodeOptionalTime(data.timestamp),
timestamp: data.timestamp ? (0, dates_1.fromRfc3339WithNanoseconds)(data.timestamp) : undefined,
signature: data.signature ? (0, encoding_1.fromBase64)(data.signature) : undefined,

@@ -225,0 +215,0 @@ };

@@ -207,12 +207,2 @@ "use strict";

}
/**
* In some cases a timestamp is optional and set to the value 0 in Go.
* This can lead to strings like "0001-01-01T00:00:00Z" (see https://github.com/cosmos/cosmjs/issues/704#issuecomment-797122415).
* This decoder tries to clean up such encoding from the API and turn them
* into undefined values.
*/
function decodeOptionalTime(timestamp) {
const nonZeroTime = timestamp && !timestamp.startsWith("0001-01-01");
return nonZeroTime ? (0, dates_1.fromRfc3339WithNanoseconds)(timestamp) : undefined;
}
function decodeCommitSignature(data) {

@@ -222,3 +212,3 @@ return {

validatorAddress: data.validator_address ? (0, encoding_1.fromHex)(data.validator_address) : undefined,
timestamp: decodeOptionalTime(data.timestamp),
timestamp: data.timestamp ? (0, dates_1.fromRfc3339WithNanoseconds)(data.timestamp) : undefined,
signature: data.signature ? (0, encoding_1.fromBase64)(data.signature) : undefined,

@@ -225,0 +215,0 @@ };

16

package.json
{
"name": "@cosmjs/tendermint-rpc",
"version": "0.32.0",
"version": "0.32.1",
"description": "Tendermint RPC clients",

@@ -45,9 +45,9 @@ "contributors": [

"dependencies": {
"@cosmjs/crypto": "^0.32.0",
"@cosmjs/encoding": "^0.32.0",
"@cosmjs/json-rpc": "^0.32.0",
"@cosmjs/math": "^0.32.0",
"@cosmjs/socket": "^0.32.0",
"@cosmjs/stream": "^0.32.0",
"@cosmjs/utils": "^0.32.0",
"@cosmjs/crypto": "^0.32.1",
"@cosmjs/encoding": "^0.32.1",
"@cosmjs/json-rpc": "^0.32.1",
"@cosmjs/math": "^0.32.1",
"@cosmjs/socket": "^0.32.1",
"@cosmjs/stream": "^0.32.1",
"@cosmjs/utils": "^0.32.1",
"axios": "^1.6.0",

@@ -54,0 +54,0 @@ "readonly-date": "^1.0.0",

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

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