MCPcopy Index your code
hub / github.com/Flagsmith/flagsmith / isPublicURL

Function isPublicURL

frontend/web/main.js:58–83  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

56}
57
58function isPublicURL() {
59 const pathname = document.location.pathname
60
61 // /oauth/authorize requires auth (consent screen), but /oauth/:type (callbacks) is public.
62 if (pathname.startsWith('/oauth/authorize')) {
63 return false
64 }
65
66 const publicPaths = [
67 '/',
68 '/404',
69 '/home',
70 '/password-reset',
71 '/maintenance',
72 '/github-setup',
73 '/oauth',
74 '/register',
75 '/saml',
76 '/signup',
77 '/login',
78 ]
79
80 return publicPaths.some(
81 (path) => pathname === path || pathname.startsWith(`${path}/`),
82 )
83}
84
85setTimeout(() => {
86 const browserHistory = createBrowserHistory({

Callers 1

main.jsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected