@polkadot/types-codec
Advanced tools
Comparing version 10.12.2 to 10.12.3
@@ -72,7 +72,7 @@ "use strict"; | ||
/** | ||
* @description Converts the Object to to a human-friendly JSON, with additional fields, expansion and formatting of information | ||
* @description Converts the Object to a human-friendly JSON, with additional fields, expansion and formatting of information | ||
*/ | ||
toHuman() { | ||
return [...this.entries()].reduce((json, [key, value]) => { | ||
json[key] = (0, util_1.isFunction)(value.toHuman) | ||
json[key] = (0, util_1.isFunction)(value?.toHuman) | ||
? value.toHuman() | ||
@@ -79,0 +79,0 @@ : value; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.packageInfo = void 0; | ||
exports.packageInfo = { name: '@polkadot/types-codec', path: typeof __dirname === 'string' ? __dirname : 'auto', type: 'cjs', version: '10.12.2' }; | ||
exports.packageInfo = { name: '@polkadot/types-codec', path: typeof __dirname === 'string' ? __dirname : 'auto', type: 'cjs', version: '10.12.3' }; |
@@ -46,3 +46,3 @@ import type { HexString } from '@polkadot/util/types'; | ||
/** | ||
* @description Converts the Object to to a human-friendly JSON, with additional fields, expansion and formatting of information | ||
* @description Converts the Object to a human-friendly JSON, with additional fields, expansion and formatting of information | ||
*/ | ||
@@ -49,0 +49,0 @@ toHuman(): Record<string, AnyJson>; |
@@ -69,7 +69,7 @@ import { isFunction, objectProperties, stringify } from '@polkadot/util'; | ||
/** | ||
* @description Converts the Object to to a human-friendly JSON, with additional fields, expansion and formatting of information | ||
* @description Converts the Object to a human-friendly JSON, with additional fields, expansion and formatting of information | ||
*/ | ||
toHuman() { | ||
return [...this.entries()].reduce((json, [key, value]) => { | ||
json[key] = isFunction(value.toHuman) | ||
json[key] = isFunction(value?.toHuman) | ||
? value.toHuman() | ||
@@ -76,0 +76,0 @@ : value; |
@@ -21,3 +21,3 @@ { | ||
"type": "module", | ||
"version": "10.12.2", | ||
"version": "10.12.3", | ||
"main": "./cjs/index.js", | ||
@@ -24,0 +24,0 @@ "module": "./index.js", |
@@ -1,1 +0,1 @@ | ||
export const packageInfo = { name: '@polkadot/types-codec', path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto', type: 'esm', version: '10.12.2' }; | ||
export const packageInfo = { name: '@polkadot/types-codec', path: (import.meta && import.meta.url) ? new URL(import.meta.url).pathname.substring(0, new URL(import.meta.url).pathname.lastIndexOf('/') + 1) : 'auto', type: 'esm', version: '10.12.3' }; |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
649493