(path: string)
| 94 | })); |
| 95 | |
| 96 | const firstPathSegment = (path: string): string | null => { |
| 97 | const pathname = path.split(/[?#]/, 1)[0] ?? ""; |
| 98 | const segment = pathname.split("/")[1]; |
| 99 | return segment && isValidOrgSlug(segment) ? segment : null; |
| 100 | }; |
| 101 | |
| 102 | const requestedOrgSelectorFromReturnTo = (returnTo: string): string | null => |
| 103 | firstPathSegment(returnTo); |
no test coverage detected