From 37fdcd78ba9b6bfc4db1369485129e160bb5f67a Mon Sep 17 00:00:00 2001 From: metamuffin Date: Sun, 23 Jan 2022 16:34:57 +0100 Subject: refactor part 2 --- source/client/index.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source/client/index.ts') diff --git a/source/client/index.ts b/source/client/index.ts index 85943eb..16118a6 100644 --- a/source/client/index.ts +++ b/source/client/index.ts @@ -4,7 +4,7 @@ import { get_query_params } from "./helper.ts" import { log } from "./logger.ts" import { Room } from "./room.ts" -export const servers = { +export const servers: RTCConfiguration = { iceServers: [{ urls: ["stun:stun1.l.google.com:19302", "stun:stun2.l.google.com:19302"] }], iceCandidatePoolSize: 10, } @@ -18,10 +18,10 @@ export const parameters = get_query_params() window.onload = () => main() -export function main() { +export function main() { log("*", "starting up") if (window.location.pathname.startsWith("/room/")) { - const room_name = window.location.pathname.substr("/room/".length) + const room_name = window.location.pathname.substring("/room/".length) const room = new Room(room_name) document.body.append(room.el) } else { -- cgit v1.2.3-70-g09d2