Skip to content

Commit

Permalink
Merge pull request #595 from cisagov/ui-remove-warning-from-legacy-wi…
Browse files Browse the repository at this point in the history
…dth-code

Remove console warnings and logs in browser
  • Loading branch information
schmelz21 authored Sep 12, 2024
2 parents c9983d2 + 469dfaf commit aca1577
Show file tree
Hide file tree
Showing 5 changed files with 1 addition and 19 deletions.
11 changes: 0 additions & 11 deletions frontend/src/App.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ import {
BrowserRouter as Router,
Switch,
Route,
Redirect,
useLocation
} from 'react-router-dom';
import { API, Auth } from 'aws-amplify';
Expand Down Expand Up @@ -103,7 +102,6 @@ const App: React.FC = () => (
<RouteGuard
exact
path="/"
render={() => <Redirect to="/inventory" />}
unauth={AuthLogin}
component={RiskWithSearch}
/>
Expand Down Expand Up @@ -227,28 +225,19 @@ const App: React.FC = () => (
<RouteGuard
exact
path="/readysetcyber"
render={() => (
<Redirect to="/readysetcyber/dashboard" />
)}
unauth={RSCLogin}
component={RSCDashboard}
/>
<RouteGuard
exact
path="/readysetcyber/create-account"
render={() => (
<Redirect to="/readysetcyber/dashboard" />
)}
unauth={RSCAuthLoginCreate}
component={RSCDashboard}
/>
<RouteGuard
exact
path="/readysetcyber/dashboard"
component={RSCDashboard}
render={() => (
<Redirect to="/readysetcyber/dashboard" />
)}
permissions={[
'globalView',
'readySetCyber',
Expand Down
5 changes: 1 addition & 4 deletions frontend/src/components/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -195,10 +195,7 @@ export const Header: React.FC<HeaderProps> = ({
width: 175,
maxWidth: 175,
padding: theme.spacing(),
paddingLeft: 0,
[theme.breakpoints.down('xl')]: {
display: 'flex'
}
paddingLeft: 0
}}
alt="CyHy Dashboard Icon Navigate Home"
/>
Expand Down
1 change: 0 additions & 1 deletion frontend/src/components/RouteGuard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,6 @@ export const RouteGuard: React.FC<AuthRedirectRouteProps> = ({

if (token && !user) {
// waiting on user profile
console.log('Token Route Check');
return null;
}

Expand Down
2 changes: 0 additions & 2 deletions frontend/src/pages/Search/Inventory.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -89,8 +89,6 @@ export const DashboardUI: React.FC<ContextType & { location: any }> = (
return filters;
}, [filters, searchTerm, setSearchTerm]);

console.log(filtersToDisplay);

return (
<Root className={classes.root}>
<Subnav
Expand Down
1 change: 0 additions & 1 deletion frontend/src/pages/Search/SortBar.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,6 @@ export const SortBar: React.FC<Props> = (props) => {
<span id="sort-by-label">Sort by: </span>
<FormControl className={classes.openFields}>
<Select
disableUnderline
labelId="sort-by-label"
value={sortField}
onChange={onSetSortField}
Expand Down

0 comments on commit aca1577

Please sign in to comment.