From 045b506e2ad395a9da6ed6e713aaa9d26473c876 Mon Sep 17 00:00:00 2001 From: Alex Holliday Date: Wed, 11 Jun 2025 10:22:17 +0800 Subject: [PATCH] remove unused component --- .../ProtectedDistributedUptimeRoute/index.jsx | 30 ------------------- 1 file changed, 30 deletions(-) delete mode 100644 client/src/Components/ProtectedDistributedUptimeRoute/index.jsx diff --git a/client/src/Components/ProtectedDistributedUptimeRoute/index.jsx b/client/src/Components/ProtectedDistributedUptimeRoute/index.jsx deleted file mode 100644 index 4a59859fe..000000000 --- a/client/src/Components/ProtectedDistributedUptimeRoute/index.jsx +++ /dev/null @@ -1,30 +0,0 @@ -import { Navigate } from "react-router-dom"; -import { useSelector } from "react-redux"; -import PropTypes from "prop-types"; - -/** - * @param {Object} props - The props passed to the ProtectedDistributedUptimeRoute component. - * @param {React.ReactNode} props.children - The children to render if the user is authenticated. - * @returns {React.ReactElement} The children wrapped in a protected route or a redirect to the login page. - */ - -const ProtectedDistributedUptimeRoute = ({ children }) => { - const distributedUptimeEnabled = useSelector( - (state) => state.ui.distributedUptimeEnabled - ); - - return distributedUptimeEnabled === true ? ( - children - ) : ( - - ); -}; - -ProtectedDistributedUptimeRoute.propTypes = { - children: PropTypes.node.isRequired, -}; - -export default ProtectedDistributedUptimeRoute;