Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
Jabis Sevón
/
gun-multiserver
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Graphs
Network
Create a new issue
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
4eb42662
authored
2020-05-02 14:11:09 +0700
by
Jabis Sevón
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
extra gun.server
1 parent
a20330fc
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 additions
and
1 deletions
server.js
server.js
View file @
4eb4266
...
...
@@ -59,7 +59,7 @@ server.on("upgrade", async function(request, socket, head) {
// Create Node
if
(
debug
)
console
.
log
(
"Create id"
,
pathname
);
// NOTE: Only works with lib/ws.js shim allowing a predefined WS as ws.web parameter in Gun constructor
gun
.
server
=
new
WebSocket
.
Server
({
noServer
:
true
,
path
:
pathname
});
//
gun.server = new WebSocket.Server({ noServer: true, path: pathname });
if
(
debug
)
console
.
log
(
"set peer"
,
request
.
headers
.
host
+
pathname
);
if
(
sig
)
{
sigs
[
pathname
]
=
sig
;
...
...
Write
Preview
Styling with
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment