server for my chess game
Bump ws from 7.5.7 to 8.8.1
Bumps [ws](https://github.com/websockets/ws) from 7.5.7 to 8.8.1.
- [Release notes](https://github.com/websockets/ws/releases)
- [Commits](https://github.com/websockets/ws/compare/7.5.7...8.8.1)
---
updated-dependencies:
- dependency-name: ws
dependency-type: direct:production
update-type: version-update:semver-major
...
Signed-off-by: dependabot[bot] <[email protected]>
| -rw-r--r-- | package-lock.json | 16 | ||||
| -rw-r--r-- | package.json | 2 | ||||
| -rw-r--r-- | src/index.js | 5 |
3 files changed, 11 insertions, 12 deletions
diff --git a/package-lock.json b/package-lock.json index d35eafc..09bc778 100644 --- a/package-lock.json +++ b/package-lock.json @@ -12,7 +12,7 @@ "@gd-com/utils": "^4.1.0", "chess.js": "^0.13.3", "pg": "^8.7.3", - "ws": "^7.4.6" + "ws": "^8.8.1" }, "engines": { "node": "16.15" @@ -167,11 +167,11 @@ } }, "node_modules/ws": { - "version": "7.5.7", - "resolved": "https://registry.npmjs.org/ws/-/ws-7.5.7.tgz", - "integrity": "sha512-KMvVuFzpKBuiIXW3E4u3mySRO2/mCHSyZDJQM5NQ9Q9KHWHWh0NHgfbRMLLrceUK5qAL4ytALJbpRMjixFZh8A==", + "version": "8.8.1", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.8.1.tgz", + "integrity": "sha512-bGy2JzvzkPowEJV++hF07hAD6niYSr0JzBNo/J29WsB57A2r7Wlc1UFcTR9IzrPvuNVO4B8LGqF8qcpsVOhJCA==", "engines": { - "node": ">=8.3.0" + "node": ">=10.0.0" }, "peerDependencies": { "bufferutil": "^4.0.1", @@ -308,9 +308,9 @@ "integrity": "sha512-VBiJxFkxiXRlUIeyMQi8s4hgvKCSjtknJv/LVYbrgALPwf5zSKmEwV9Lst25AkvMDnvxODugjdl6KZgwKM1WYQ==" }, "ws": { - "version": "7.5.7", - "resolved": "https://registry.npmjs.org/ws/-/ws-7.5.7.tgz", - "integrity": "sha512-KMvVuFzpKBuiIXW3E4u3mySRO2/mCHSyZDJQM5NQ9Q9KHWHWh0NHgfbRMLLrceUK5qAL4ytALJbpRMjixFZh8A==", + "version": "8.8.1", + "resolved": "https://registry.npmjs.org/ws/-/ws-8.8.1.tgz", + "integrity": "sha512-bGy2JzvzkPowEJV++hF07hAD6niYSr0JzBNo/J29WsB57A2r7Wlc1UFcTR9IzrPvuNVO4B8LGqF8qcpsVOhJCA==", "requires": {} }, "xtend": { diff --git a/package.json b/package.json index 0880505..d4ebf02 100644 --- a/package.json +++ b/package.json @@ -14,7 +14,7 @@ "@gd-com/utils": "^4.1.0", "chess.js": "^0.13.3", "pg": "^8.7.3", - "ws": "^7.4.6" + "ws": "^8.8.1" }, "engines": { "node": "16.15" diff --git a/src/index.js b/src/index.js index 3805116..f614c13 100644 --- a/src/index.js +++ b/src/index.js @@ -1,8 +1,7 @@ -import ws from "ws"; -const { Server } = ws; +import { WebSocketServer } from "ws"; const PORT = process.env.PORT || 3000; -const wss = new Server({ port: PORT }); // init server asap +const wss = new WebSocketServer({ port: PORT }); // init server asap import utils from "@gd-com/utils"; const { putVar, getVar } = utils; |