MCPcopy Index your code
hub / github.com/chartbrew/chartbrew / authenticatePage

Function authenticatePage

client/src/containers/Main.jsx:57–80  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

55import NoAccessPage from "../components/NoAccessPage";
56
57function authenticatePage() {
58 if (window.location.pathname === "/login") {
59 return false;
60 } else if (window.location.pathname === "/signup") {
61 return false;
62 } else if (window.location.pathname.indexOf("/b/") > -1) {
63 return false;
64 } else if (window.location.pathname.indexOf("/report/") > -1) {
65 return false;
66 } else if (window.location.pathname === "/passwordReset") {
67 return false;
68 } else if (window.location.pathname === "/invite") {
69 return false;
70 } else if (window.location.pathname === "/feedback") {
71 return false;
72 } else if (window.location.pathname.indexOf("embedded") > -1) {
73 return false;
74 } else if (window.location.pathname.indexOf("/share") > -1) {
75 return false;
76 }
77
78 window.location.pathname = "/login";
79 return true;
80}
81
82/*
83 The main component where the entire app routing resides

Callers 1

MainFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected