diff --git a/src/components/lastAdded/FooterNav.astro b/src/components/lastAdded/FooterNav.astro
index ed4f776..edbdb65 100644
--- a/src/components/lastAdded/FooterNav.astro
+++ b/src/components/lastAdded/FooterNav.astro
@@ -22,7 +22,7 @@ const currentList = pageList[currentListIndex]
{
- currentListIndex > 0 && (
+ currentListIndex > 0 ? (
<>
«
@@ -31,7 +31,7 @@ const currentList = pageList[currentListIndex]
<
>
- )
+ ) : null
}
{
currentList.map((item) => (
@@ -44,7 +44,7 @@ const currentList = pageList[currentListIndex]
))
}
{
- currentListIndex !== pageList.length - 1 && (
+ currentListIndex !== pageList.length - 1 ? (
<>
»
>
- )
+ ) : null
}
diff --git a/src/pages/last-added/[...page].astro b/src/pages/last-added/[...page].astro
index d2ba109..b71a517 100644
--- a/src/pages/last-added/[...page].astro
+++ b/src/pages/last-added/[...page].astro
@@ -12,7 +12,7 @@ const limitMD = 12
const limitXS = 5
if (page < 1) {
- return Astro.redirect('/last-added')
+ Astro.redirect('/last-added')
}
const lastAlbums = await prismaClient.albums.findMany({
@@ -25,7 +25,7 @@ const lastAlbums = await prismaClient.albums.findMany({
const count = await prismaClient.albums.count({ where: { status: 'show' } })
if (lastAlbums.length === 0) {
- return Astro.redirect('/404')
+ Astro.redirect('/404')
}
const fullPageList = [...Array(Math.ceil(count / take))].map((v, i) => i + 1)
@@ -47,8 +47,8 @@ const listProps = { fullPageList, page }