mirror of
https://github.com/thelounge/thelounge
synced 2024-11-24 21:13:06 +00:00
server: actually type the socket
This commit is contained in:
parent
e9ef59b641
commit
843db1727b
1 changed files with 3 additions and 1 deletions
|
@ -3,7 +3,7 @@ import {Server as wsServer} from "ws";
|
|||
import express, {NextFunction, Request, Response} from "express";
|
||||
import fs from "fs";
|
||||
import path from "path";
|
||||
import {Server, Socket} from "socket.io";
|
||||
import {Server, Socket as ioSocket} from "socket.io";
|
||||
import dns from "dns";
|
||||
import colors from "chalk";
|
||||
import net from "net";
|
||||
|
@ -51,6 +51,8 @@ type IndexTemplateConfiguration = ServerConfiguration & {
|
|||
cacheBust: string;
|
||||
};
|
||||
|
||||
type Socket = ioSocket<ClientToServerEvents, ServerToClientEvents, InterServerEvents, SocketData>;
|
||||
|
||||
// A random number that will force clients to reload the page if it differs
|
||||
const serverHash = Math.floor(Date.now() * Math.random());
|
||||
|
||||
|
|
Loading…
Reference in a new issue