Pusher federation
Source: https://gist.github.com/jstsmthrgk/2c82124c9ac2bd453658f52c90b8dd44
This commit is contained in:
parent
f1c999ffc1
commit
185d3b58ed
5 changed files with 33 additions and 10 deletions
|
@ -195,7 +195,11 @@ export class IoSocketController {
|
|||
const websocketExtensions = req.getHeader("sec-websocket-extensions");
|
||||
const IPAddress = req.getHeader("x-forwarded-for");
|
||||
|
||||
const roomId = query.roomId;
|
||||
const roomId =
|
||||
typeof query.roomId != "string"
|
||||
? query.roomId
|
||||
: "https://dummy.fediventure.net/_/global" +
|
||||
query.roomId.replace(new RegExp("[^_]*_/[^/]*/"), "/");
|
||||
try {
|
||||
if (typeof roomId !== "string") {
|
||||
throw new Error("Undefined room ID: ");
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue