From f85d40d8c6cc2f3b58d1e0ea7f0382db88fffd4e Mon Sep 17 00:00:00 2001 From: metamuffin Date: Tue, 17 Jan 2023 22:28:35 +0100 Subject: refer to room name as secret instead --- client-web/source/preferences/mod.ts | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'client-web/source/preferences/mod.ts') diff --git a/client-web/source/preferences/mod.ts b/client-web/source/preferences/mod.ts index 5de73eb..04fae2c 100644 --- a/client-web/source/preferences/mod.ts +++ b/client-web/source/preferences/mod.ts @@ -85,19 +85,19 @@ export function generate_section(): string { PREFS_EXPLICIT[key as unknown as keyof typeof PREFS_EXPLICIT] ))) } - return load_params().rname + "?" + section.join("&") + return load_params().rsecret + "?" + section.join("&") } -export function load_params(): { raw_params: { [key: string]: string }, rname: string } { +export function load_params(): { raw_params: { [key: string]: string }, rsecret: string } { const raw_params: Record = {} - const [rname, param_str] = window.location.hash.substring(1).split("?") - if (!param_str) return { rname, raw_params: {} } + const [rsecret, param_str] = window.location.hash.substring(1).split("?") + if (!param_str) return { rsecret, raw_params: {} } for (const kv of param_str.split("&")) { const [key, value] = kv.split("=") if (key == "prototype") continue raw_params[decodeURIComponent(key)] = decodeURIComponent(value) } - return { raw_params, rname } + return { raw_params, rsecret } } function get_param(ty: string, key: string): T | undefined { -- cgit v1.2.3-70-g09d2