From 56be3a12f3cc9461f0df0b8014b6c10b83ac2e32 Mon Sep 17 00:00:00 2001 From: Andrey Polischuk Date: Tue, 19 Mar 2024 14:19:55 +0300 Subject: [PATCH] fix: reset error after a successful getting data --- src/components/routes.tsx | 1 + 1 file changed, 1 insertion(+) diff --git a/src/components/routes.tsx b/src/components/routes.tsx index 16861b9..395bd31 100644 --- a/src/components/routes.tsx +++ b/src/components/routes.tsx @@ -74,6 +74,7 @@ export const Routes: React.FC = ({ window.scrollTo(0, 0) } + setError(null) setRouteData((previousData) => ({...previousData, ...data})) setCurrentLocation(location) onChangeMetaData?.(meta)