@matterlabs/hardhat-zksync-node
Advanced tools
Comparing version
@@ -158,3 +158,3 @@ "use strict"; | ||
// Get the URL from the 'location' header | ||
if (response.headers.location) { | ||
if (response.headers.location && typeof response.headers.location === 'string') { | ||
// Check if the redirect URL matches the expected pattern | ||
@@ -244,3 +244,6 @@ if (response.headers.location.startsWith(redirectUrlPattern)) { | ||
method: 'GET', | ||
headers: Object.assign(Object.assign({}, extraHeaders), { 'User-Agent': `${userAgent} ${version}` }), | ||
headers: { | ||
...extraHeaders, | ||
'User-Agent': `${userAgent} ${version}`, | ||
}, | ||
}); | ||
@@ -247,0 +250,0 @@ if (response.statusCode >= 200 && response.statusCode <= 299) { |
@@ -15,5 +15,4 @@ "use strict"; | ||
async request(payload) { | ||
var _a; | ||
// @ts-ignore | ||
return await this._zkSyncProvider.send(payload.method, (_a = payload.params) !== null && _a !== void 0 ? _a : []); | ||
return await this._zkSyncProvider.send(payload.method, payload.params ?? []); | ||
} | ||
@@ -20,0 +19,0 @@ async sendAsync(payload, callback) { |
{ | ||
"name": "@matterlabs/hardhat-zksync-node", | ||
"version": "0.1.0", | ||
"version": "0.2.0", | ||
"description": "Hardhat plugin to run zkSync era-test-node locally", | ||
@@ -18,13 +18,2 @@ "repository": "github:matter-labs/hardhat-zksync", | ||
], | ||
"scripts": { | ||
"lint": "yarn eslint", | ||
"prettier:check": "yarn prettier --check", | ||
"lint:fix": "yarn eslint --fix", | ||
"fmt": "yarn prettier --write", | ||
"eslint": "eslint 'src/**/*.ts' 'test/**/*.ts'", | ||
"prettier": "prettier 'src/**/*.ts' 'test/**/*.ts'", | ||
"test": "mocha test/tests.ts --exit", | ||
"build": "tsc --build .", | ||
"clean": "rimraf dist" | ||
}, | ||
"files": [ | ||
@@ -37,39 +26,39 @@ "dist/", | ||
"dependencies": { | ||
"@matterlabs/hardhat-zksync-solc": "^1.1.4", | ||
"axios": "^1.4.0", | ||
"chalk": "4.1.2", | ||
"fs-extra": "^11.1.1", | ||
"@matterlabs/hardhat-zksync-solc": "^1.2.0", | ||
"axios": "^1.7.2", | ||
"chalk": "^4.1.2", | ||
"fs-extra": "^11.2.0", | ||
"sinon-chai": "^3.7.0", | ||
"proxyquire": "^2.1.3", | ||
"sinon": "^17.0.1", | ||
"chai": "^4.3.6", | ||
"undici": "^5.14.0" | ||
"sinon": "^18.0.0", | ||
"chai": "^4.3.4", | ||
"undici": "^6.18.2" | ||
}, | ||
"devDependencies": { | ||
"@types/chai": "^4.2.0", | ||
"@types/fs-extra": "^5.1.0", | ||
"@types/mocha": "^9.1.0", | ||
"@types/chai": "^4.3.16", | ||
"@types/fs-extra": "^11.0.4", | ||
"@types/mocha": "^10.0.6", | ||
"@types/node": "^18.11.17", | ||
"@types/proxyquire": "^1.3.29", | ||
"@types/sinon-chai": "^3.2.10", | ||
"@typescript-eslint/eslint-plugin": "6.13.1", | ||
"@typescript-eslint/parser": "6.13.1", | ||
"eslint": "^8.54.0", | ||
"eslint-config-prettier": "9.0.0", | ||
"eslint-plugin-import": "2.29.0", | ||
"eslint-plugin-no-only-tests": "3.1.0", | ||
"eslint-plugin-prettier": "5.0.1", | ||
"@typescript-eslint/eslint-plugin": "^7.12.0", | ||
"@typescript-eslint/parser": "^7.12.0", | ||
"eslint": "^8.56.0", | ||
"eslint-config-prettier": "^9.1.0", | ||
"eslint-plugin-import": "^2.29.1", | ||
"eslint-plugin-no-only-tests": "^3.1.0", | ||
"eslint-plugin-prettier": "^5.0.1", | ||
"hardhat": "^2.14.0", | ||
"mocha": "^9.2.1", | ||
"prettier": "3.1.0", | ||
"rimraf": "^3.0.2", | ||
"ts-node": "^10.6.0", | ||
"typescript": "^5.1.6", | ||
"zksync-ethers": "^5.0.0", | ||
"c8": "^8.0.1", | ||
"ethers": "~5.7.2" | ||
"mocha": "^10.4.0", | ||
"prettier": "^3.3.0", | ||
"rimraf": "^5.0.7", | ||
"ts-node": "^10.9.2", | ||
"typescript": "^5.3.0", | ||
"zksync-ethers": "^5.8.0", | ||
"ethers": "~5.7.2", | ||
"c8": "^9.1.0" | ||
}, | ||
"peerDependencies": { | ||
"hardhat": "^2.14.0", | ||
"zksync-ethers": "^5.0.0" | ||
"zksync-ethers": "^5.8.0" | ||
}, | ||
@@ -82,3 +71,14 @@ "prettier": { | ||
"bracketSpacing": true | ||
}, | ||
"scripts": { | ||
"lint": "pnpm eslint", | ||
"prettier:check": "pnpm prettier --check", | ||
"lint:fix": "pnpm eslint --fix", | ||
"fmt": "pnpm prettier --write", | ||
"eslint": "eslint 'src/**/*.ts' 'test/**/*.ts'", | ||
"prettier": "prettier 'src/**/*.ts' 'test/**/*.ts'", | ||
"test": "mocha test/tests.ts --exit", | ||
"build": "tsc --build .", | ||
"clean": "rimraf dist" | ||
} | ||
} | ||
} |
@@ -172,3 +172,3 @@ import path from 'path'; | ||
// Get the URL from the 'location' header | ||
if (response.headers.location) { | ||
if (response.headers.location && typeof response.headers.location === 'string') { | ||
// Check if the redirect URL matches the expected pattern | ||
@@ -175,0 +175,0 @@ if (response.headers.location.startsWith(redirectUrlPattern)) { |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Potential vulnerability
Supply chain riskInitial human review suggests the presence of a vulnerability in this package. It is pending further analysis and confirmation.
Found 1 instance in 1 package
115690
0.09%1813
0.11%4
-20%- Removed
- Removed
- Removed
Updated
Updated
Updated
Updated
Updated
Updated