next.config: fix /login redirect self-loop, point at /client-login
This commit is contained in:
@@ -84,12 +84,12 @@ const nextConfig = {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
source: '/wp-login.php',
|
source: '/wp-login.php',
|
||||||
destination: '/login',
|
destination: '/client-login',
|
||||||
permanent: true,
|
permanent: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
source: '/wp-login.php/:path*',
|
source: '/wp-login.php/:path*',
|
||||||
destination: '/login',
|
destination: '/client-login',
|
||||||
permanent: true,
|
permanent: true,
|
||||||
},
|
},
|
||||||
// Catch-all for any other wp-admin sub-paths
|
// Catch-all for any other wp-admin sub-paths
|
||||||
@@ -112,18 +112,18 @@ const nextConfig = {
|
|||||||
},
|
},
|
||||||
{
|
{
|
||||||
source: '/avbeat/wp-login.php',
|
source: '/avbeat/wp-login.php',
|
||||||
destination: '/login',
|
destination: '/client-login',
|
||||||
permanent: true,
|
permanent: true,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
source: '/avbeat/wp-login.php/:path*',
|
source: '/avbeat/wp-login.php/:path*',
|
||||||
destination: '/login',
|
destination: '/client-login',
|
||||||
permanent: true,
|
permanent: true,
|
||||||
},
|
},
|
||||||
// Login aliases
|
// Login alias — /login redirects to canonical /client-login
|
||||||
{
|
{
|
||||||
source: '/login',
|
source: '/login',
|
||||||
destination: '/login',
|
destination: '/client-login',
|
||||||
permanent: false,
|
permanent: false,
|
||||||
},
|
},
|
||||||
];
|
];
|
||||||
|
|||||||
Reference in New Issue
Block a user