type serverOptions for network:options

This commit is contained in:
Reto Brunner 2024-04-14 01:08:27 +02:00
parent 9898f38de6
commit bb7c3925c6
2 changed files with 3 additions and 3 deletions

View file

@ -23,7 +23,7 @@ socket.on("network:options", function (data) {
const network = store.getters.findNetwork(data.network);
if (network) {
network.serverOptions = data.serverOptions as typeof network.serverOptions;
network.serverOptions = data.serverOptions;
}
});

View file

@ -1,6 +1,6 @@
import {SharedMention} from "./mention";
import {ChanState, SharedChan} from "./chan";
import {SharedNetwork} from "./network";
import {SharedNetwork, SharedServerOptions} from "./network";
import {SharedMsg, LinkPreview} from "./msg";
import {SharedUser} from "./user";
import {SharedChangelogData} from "./changelog";
@ -54,7 +54,7 @@ interface ServerToClientEvents {
names: EventHandler<{id: number; users: SharedUser[]}>;
network: EventHandler<{network: SharedNetwork}>;
"network:options": EventHandler<{network: string; serverOptions: {[key: string]: any}}>;
"network:options": EventHandler<{network: string; serverOptions: SharedServerOptions}>;
"network:status": EventHandler<{network: string; connected: boolean; secure: boolean}>;
"network:info": EventHandler<{uuid: string}>;
"network:name": EventHandler<{uuid: string; name: string}>;