diff --git a/src/components/HeaderBar.tsx b/src/components/HeaderBar.tsx
index c91a8c3..c584d67 100644
--- a/src/components/HeaderBar.tsx
+++ b/src/components/HeaderBar.tsx
@@ -94,22 +94,39 @@ export default function HeaderBar(props: Props) {
}));
const navigate = useNavigate();
- const loaction = useLocation();
+ const location = useLocation();
+
+ function leftButton() {
+ if(location.pathname.split("/")[1] === "foodpage") {
+ return (
+ navigate(-1)}
+ >
+
+
+ )
+ }
+ return (
+
+
+
+ )
+ }
return (
- {loaction.pathname.split("/")[1] === "foodpage" && (
- navigate(-1)}
- >
-
-
- )}
+ {leftButton()}
-
-
-
);