Socket
Socket
Sign inDemoInstall

@ethersproject/bytes

Package Overview
Dependencies
1
Maintainers
1
Versions
45
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

Comparing version 6.0.0-beta.1 to 6.0.0-beta.2

README.md

2

lib/_version.d.ts

@@ -1,2 +0,2 @@

export declare const version = "@ethersproject/bytes@6.0.0-beta.1";
export declare const version = "@ethersproject/bytes@6.0.0-beta.2";
//# sourceMappingURL=_version.d.ts.map

@@ -1,2 +0,2 @@

export const version = "@ethersproject/bytes@6.0.0-beta.1";
export const version = "@ethersproject/bytes@6.0.0-beta.2";
//# sourceMappingURL=_version.js.map

@@ -20,7 +20,7 @@ import { isBytesLike } from "./check.js";

if (typeof (data) === "number") {
logger.assertUint53(data);
let v = logger.getNumber(data, "data");
const result = [];
while (data) {
result.unshift(data & 0xff);
data = parseInt(String(data / 256));
while (v) {
result.unshift(v & 0xff);
v = parseInt(String(v / 256));
}

@@ -27,0 +27,0 @@ if (result.length === 0) {

@@ -6,4 +6,4 @@ export { arrayify } from "./array.js";

export { hexlify, quantity } from "./hex.js";
export { zeroPadLeft, zeroPadRight } from "./pad.js";
export { zeroPadBytes, zeroPadValue } from "./pad.js";
export type { BytesLike, Hexable } from "./types.js";
//# sourceMappingURL=index.d.ts.map

@@ -6,3 +6,3 @@ export { arrayify } from "./array.js";

export { hexlify, quantity } from "./hex.js";
export { zeroPadLeft, zeroPadRight } from "./pad.js";
export { zeroPadBytes, zeroPadValue } from "./pad.js";
//# sourceMappingURL=index.js.map
import type { BytesLike } from "./types.js";
export declare function zeroPadLeft(data: BytesLike, length: number): string;
export declare function zeroPadRight(data: BytesLike, length: number): string;
export declare function zeroPadValue(data: BytesLike, length: number): string;
export declare function zeroPadBytes(data: BytesLike, length: number): string;
//# sourceMappingURL=pad.d.ts.map

@@ -23,8 +23,8 @@ import { _noCopyArrayify } from "./array.js";

}
export function zeroPadLeft(data, length) {
export function zeroPadValue(data, length) {
return zeroPad(data, length, true);
}
export function zeroPadRight(data, length) {
export function zeroPadBytes(data, length) {
return zeroPad(data, length, false);
}
//# sourceMappingURL=pad.js.map

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

"ethereum": "donations.ethers.eth",
"gitHead": "77f691b3bc3a6387a5184ec9b1779faab4bcb30d",
"gitHead": "4fcde0967317451fac6cec6addba8258f98c14b5",
"keywords": [

@@ -33,6 +33,6 @@ "Ethereum",

"sideEffects": false,
"tarballHash": "0xe518b1ceca91f872c4e77d7a4582d537014e542f246ed16268f5188425d3bd56",
"tarballHash": "0x397121eb77470b12cbd8fc8885310ef796c304a643f7de05cc47d735fa8ecaf7",
"type": "module",
"types": "./lib/index.d.ts",
"version": "6.0.0-beta.1"
"version": "6.0.0-beta.2"
}

@@ -1,1 +0,1 @@

export const version = "@ethersproject/bytes@6.0.0-beta.1";
export const version = "@ethersproject/bytes@6.0.0-beta.2";

@@ -26,8 +26,8 @@ import { isBytesLike } from "./check.js";

if (typeof(data) === "number") {
logger.assertUint53(data);
let v = logger.getNumber(data, "data");
const result = [];
while (data) {
result.unshift(data & 0xff);
data = parseInt(String(data / 256));
while (v) {
result.unshift(v & 0xff);
v = parseInt(String(v / 256));
}

@@ -34,0 +34,0 @@ if (result.length === 0) { result.push(0); }

@@ -7,4 +7,4 @@

export { hexlify, quantity } from "./hex.js";
export { zeroPadLeft, zeroPadRight } from "./pad.js";
export { zeroPadBytes, zeroPadValue } from "./pad.js";
export type { BytesLike, Hexable } from "./types.js";

@@ -30,8 +30,8 @@

export function zeroPadLeft(data: BytesLike, length: number): string {
export function zeroPadValue(data: BytesLike, length: number): string {
return zeroPad(data, length, true);
}
export function zeroPadRight(data: BytesLike, length: number): string {
export function zeroPadBytes(data: BytesLike, length: number): string {
return zeroPad(data, length, false);
}

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

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

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc