@live-change/server 0.8.8 → 0.8.10

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/lib/SsrServer.js +5 -1
  2. package/package.json +7 -7
package/lib/SsrServer.js CHANGED
@@ -81,7 +81,11 @@ class SsrServer {
81
81
  async setupSsr() {
82
82
  const readCredentials = this.settings.readCredentials || ((req) => {
83
83
  const cookies = cookie.parse(req.headers.cookie || '')
84
- return { sessionKey: cookies.sessionKey || crypto.randomBytes(64).toString('base64').slice(0, 48) }
84
+ return {
85
+ sessionKey: req.query.sessionKey
86
+ || cookies.sessionKey
87
+ || crypto.randomBytes(64).toString('base64').slice(0, 48)
88
+ }
85
89
  })
86
90
  const writeCredentials = this.settings.writeCredentials || ((res, credentials) => {
87
91
  //console.log("WRITE CREDENTIALS", credentials)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@live-change/server",
3
- "version": "0.8.8",
3
+ "version": "0.8.10",
4
4
  "description": "Live Change Framework - server",
5
5
  "main": "index.js",
6
6
  "scripts": {
@@ -22,12 +22,12 @@
22
22
  "type": "module",
23
23
  "homepage": "https://github.com/live-change/live-change-framework",
24
24
  "dependencies": {
25
- "@live-change/dao": "^0.8.8",
26
- "@live-change/dao-sockjs": "^0.8.8",
27
- "@live-change/db-server": "^0.8.8",
28
- "@live-change/framework": "^0.8.8",
25
+ "@live-change/dao": "^0.8.10",
26
+ "@live-change/dao-sockjs": "^0.8.10",
27
+ "@live-change/db-server": "^0.8.10",
28
+ "@live-change/framework": "^0.8.10",
29
29
  "@live-change/sockjs": "0.4.1",
30
- "@live-change/uid": "^0.8.8",
30
+ "@live-change/uid": "^0.8.10",
31
31
  "dotenv": "^16.4.4",
32
32
  "express": "^4.18.2",
33
33
  "express-static-gzip": "2.1.7",
@@ -39,5 +39,5 @@
39
39
  "websocket": "^1.0.34",
40
40
  "yargs": "^17.7.2"
41
41
  },
42
- "gitHead": "77eafa414e091c8d34ae63ee8927d53f3bde893d"
42
+ "gitHead": "b6d6d60903abd25c8da4a55f653aafafb6cf04f7"
43
43
  }