tsconfig: Enable noUncheckedIndexedAccess.

Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
Anders Kaseorg
2024-05-23 15:02:38 -07:00
parent 4e91572c96
commit 804c3706ff
61 changed files with 210 additions and 205 deletions

View File

@@ -270,7 +270,7 @@ export function slug_to_name(slug: string): string {
*/
const m = /^(\d+)(-.*)?$/.exec(slug);
if (m) {
const stream_id = Number.parseInt(m[1], 10);
const stream_id = Number.parseInt(m[1]!, 10);
const sub = sub_store.get(stream_id);
if (sub) {
return sub.name;