b11153a
1
2
3
4
5
6
export const SAFE_NEXT = /^\/([^/\\]|$)/; export function safeNext(next: string | null, fallback = '/'): string { return next !== null && SAFE_NEXT.test(next) ? next : fallback; }