optional chain

This commit is contained in:
Miodec 2022-07-02 14:34:01 +02:00
parent da61bfb83c
commit 9acd68e99f

View file

@ -194,6 +194,6 @@ export function recordAuthTime(
path: string,
time: number
): void {
const pathNoGet = path.replace(/\?.*/, "");
const pathNoGet = path?.replace(/\?.*/, "");
authTime.observe({ type, status, path: pathNoGet }, time);
}