From c9fcdf9f50d8dd14f31a2243705cd57f0822e274 Mon Sep 17 00:00:00 2001 From: "Mikal S." <7761729+revam@users.noreply.github.com> Date: Sun, 17 Nov 2024 20:07:43 +0100 Subject: [PATCH] fix: navigate back upon saving tmdb links (#1144) --- src/pages/collection/series/TmdbLinking.tsx | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/pages/collection/series/TmdbLinking.tsx b/src/pages/collection/series/TmdbLinking.tsx index 2ee39eb4..4b0c0f00 100644 --- a/src/pages/collection/series/TmdbLinking.tsx +++ b/src/pages/collection/series/TmdbLinking.tsx @@ -240,6 +240,8 @@ const TmdbLinking = () => { } else { toast.success('Episode links have been updated!'); } + // Note: The tmdb linking page's parent is the collection page, so we need to navigate from the collection page to the series page, even though we use the series id on the tmdb linking page too. + navigate(`../series/${seriesId}`); } catch (error) { toast.error('Failed to save links!'); } @@ -272,6 +274,8 @@ const TmdbLinking = () => { resetQueries(['series', seriesId]); setLinkOverrides({}); toast.success('Links saved!'); + // Note: The tmdb linking page's parent is the collection page, so we need to navigate from the collection page to the series page, even though we use the series id on the tmdb linking page too. + navigate(`../series/${seriesId}`); } catch (error) { console.error(error); toast.error('Failed to save links!');