Open reader via the correct url when using resume FAB (#355)
With the recent update to react-router-dom v6 the route "manga/:mangaId/chapter/:chapterIndex/page/:pageIndex" doesn't get matched anymore. The "pageIndex" is also unnecessary since it doesn't get used and instead the chapters "lastReadPage" property gets used to resume the chapter.
This commit is contained in:
@@ -23,7 +23,7 @@ export default function ResumeFab(props: ResumeFABProps) {
|
||||
const { t } = useTranslation();
|
||||
|
||||
const {
|
||||
chapter: { index, lastPageRead },
|
||||
chapter: { index },
|
||||
mangaId,
|
||||
} = props;
|
||||
return (
|
||||
@@ -31,7 +31,7 @@ export default function ResumeFab(props: ResumeFABProps) {
|
||||
component={Link}
|
||||
variant="extended"
|
||||
color="primary"
|
||||
to={`/manga/${mangaId}/chapter/${index}/page/${lastPageRead}`}
|
||||
to={`/manga/${mangaId}/chapter/${index}`}
|
||||
state={{ backLink: BACK }}
|
||||
>
|
||||
<PlayArrow />
|
||||
|
||||
Reference in New Issue
Block a user