Renombrar /login -> /log-in en toda la web (/login da 404)
Mueve la página de login a /log-in y actualiza todas las referencias (enlace CONECTAR del header y los redirect de auth de ~45 páginas). /login ahora da 404. La API /api/auth/login no se toca (solo la ruta de página). Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -13,7 +13,7 @@ export default async function AdminForumPage({ params }: { params: Promise<{ loc
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
const groups = await listCategoriesWithForums()
|
||||
return (
|
||||
|
||||
@@ -13,7 +13,7 @@ export default async function AdminGoldPage({ params }: { params: Promise<{ loca
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
const options = await listGoldOptions()
|
||||
return (
|
||||
|
||||
@@ -13,7 +13,7 @@ export default async function AdminNewsPage({ params }: { params: Promise<{ loca
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
const news = await listNews()
|
||||
return (
|
||||
|
||||
@@ -11,7 +11,7 @@ export default async function AdminPage({ params }: { params: Promise<{ locale:
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
|
||||
const items: { href: string; label: string; icon: string }[] = [
|
||||
|
||||
@@ -13,7 +13,7 @@ export default async function AdminPricesPage({ params }: { params: Promise<{ lo
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
const prices = await getAllPrices()
|
||||
return (
|
||||
|
||||
@@ -13,7 +13,7 @@ export default async function AdminPromoPage({ params }: { params: Promise<{ loc
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
const codes = await listPromoCodes()
|
||||
return (
|
||||
|
||||
@@ -13,7 +13,7 @@ export default async function AdminRecruitPage({ params }: { params: Promise<{ l
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
const rewards = await listRecruitRewards()
|
||||
return (
|
||||
|
||||
@@ -12,7 +12,7 @@ export default async function AdminUsersPage({ params }: { params: Promise<{ loc
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
return (
|
||||
<PageShell title={t('users')}>
|
||||
|
||||
@@ -13,7 +13,7 @@ export default async function AdminVotesPage({ params }: { params: Promise<{ loc
|
||||
setRequestLocale(locale)
|
||||
const t = await getTranslations('Admin')
|
||||
const session = await getSession()
|
||||
if (!session.bnetId) redirect({ href: '/login', locale })
|
||||
if (!session.bnetId) redirect({ href: '/log-in', locale })
|
||||
if (!(await isAdmin(session))) redirect({ href: '/', locale })
|
||||
const sites = await listVoteSites()
|
||||
return (
|
||||
|
||||
Reference in New Issue
Block a user