Skip to content

Commit

Permalink
deps: update and edit root dependencies (#426)
Browse files Browse the repository at this point in the history
* Update prettier

* Update packages

* Update packages

* Remove @types

* Remove chalk

* Remove @types/madge

* Update packages

* Update packages

* Update @typescript-eslint/eslint-plugin

* style: resolve style guide violations

---------

Co-authored-by: sebastijankuzner <[email protected]>
  • Loading branch information
sebastijankuzner and sebastijankuzner authored Feb 7, 2024
1 parent 2a14fdf commit 52516f2
Show file tree
Hide file tree
Showing 4 changed files with 303 additions and 243 deletions.
1 change: 1 addition & 0 deletions .eslintrc.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,7 @@ module.exports = {
"@typescript-eslint/no-unsafe-member-access": "off",
"@typescript-eslint/no-unsafe-return": "off",
"@typescript-eslint/no-unused-vars": "off",
"@typescript-eslint/no-unnecessary-type-assertion": "off",
"@typescript-eslint/no-var-requires": "off",
"@typescript-eslint/require-await": "off",
"@typescript-eslint/restrict-plus-operands": "off",
Expand Down
38 changes: 15 additions & 23 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,45 +30,37 @@
"workflows:unit": "node scripts/generate-unit-workflow.js"
},
"devDependencies": {
"@types/chalk": "^2.2.0",
"@types/eslint": "^8.44.9",
"@types/eslint-config-prettier": "^6.11.3",
"@types/eslint-plugin-prettier": "^3.1.3",
"@types/lint-staged": "^13.2.2",
"@types/madge": "^5.0.3",
"@types/node": "20.10.4",
"@types/prettier": "^2.7.3",
"@typescript-eslint/eslint-plugin": "^6.14",
"@typescript-eslint/parser": "^6.14",
"c8": "^8.0.1",
"chalk": "^4.1.2",
"@types/node": "20.11.16",
"@typescript-eslint/eslint-plugin": "^6.21.0",
"@typescript-eslint/parser": "^6.21.0",
"c8": "^9.1.0",
"cross-env": "^7.0.3",
"del-cli": "^5.1.0",
"depcheck": "^1.4.7",
"eslint": "^8.55.0",
"eslint": "^8.56.0",
"eslint-config-prettier": "^9.1.0",
"eslint-plugin-import": "^2.29.0",
"eslint-plugin-import": "^2.29.1",
"eslint-plugin-jsx-a11y": "^6.8.0",
"eslint-plugin-prettier": "^5.0.1",
"eslint-plugin-prettier": "^5.1.3",
"eslint-plugin-promise": "^6.1.1",
"eslint-plugin-simple-import-sort": "^10.0.0",
"eslint-plugin-sonarjs": "^0.23.0",
"eslint-plugin-sort-keys-fix": "^1.1.2",
"eslint-plugin-testcafe": "^0.2.1",
"eslint-plugin-testing-library": "^6.2.0",
"eslint-plugin-unicorn": "^49.0.0",
"eslint-plugin-unicorn": "^51.0.1",
"eslint-plugin-unused-imports": "^3.0.0",
"husky": "^8.0.3",
"husky": "^9.0.10",
"lerna": "^6.6.2",
"lint-staged": "^15.2.0",
"lint-staged": "^15.2.2",
"madge": "^6.1.0",
"npm-check-updates": "^16.14.12",
"prettier": "^3.1.1",
"sort-package-json": "^2.6.0",
"npm-check-updates": "^16.14.14",
"prettier": "^3.2.5",
"sort-package-json": "^2.7.0",
"tsm": "^2.3.0",
"typedoc": "^0.25.4",
"typedoc": "^0.25.7",
"typescript": "5.3.3",
"typesync": "^0.11.1",
"typesync": "^0.12.1",
"yaml": "^2.3.4"
}
}
15 changes: 8 additions & 7 deletions packages/p2p/source/service-provider.ts
Original file line number Diff line number Diff line change
Expand Up @@ -97,13 +97,14 @@ export class ServiceProvider extends Providers.ServiceProvider {

this.app
.bind(Identifiers.P2P.ApiNode.Factory)
.toFactory<ApiNode, [string, string | number, Contracts.P2P.PeerProtocol?]>(
() => (ip: string, port: string | number, protocol?: Contracts.P2P.PeerProtocol) => {
const sanitizedIp = sanitizeRemoteAddress(ip);
Utils.assert.defined<string>(sanitizedIp);
return this.app.resolve(ApiNode).init(sanitizedIp, Number(port), protocol);
},
);
.toFactory<
ApiNode,
[string, string | number, Contracts.P2P.PeerProtocol?]
>(() => (ip: string, port: string | number, protocol?: Contracts.P2P.PeerProtocol) => {
const sanitizedIp = sanitizeRemoteAddress(ip);
Utils.assert.defined<string>(sanitizedIp);
return this.app.resolve(ApiNode).init(sanitizedIp, Number(port), protocol);
});

this.app
.bind(Identifiers.P2P.Header.Factory)
Expand Down
Loading

0 comments on commit 52516f2

Please sign in to comment.