mirror of
https://github.com/TheRealOwenRees/echecsfrance.git
synced 2026-07-22 20:16:57 +00:00
env update
This commit is contained in:
@@ -0,0 +1 @@
|
||||
NEXT_PUBLIC_URL=http://localhost:3000
|
||||
@@ -0,0 +1 @@
|
||||
NEXT_PUBLIC_URL=https://$NEXT_PUBLIC_VERCEL_URL
|
||||
@@ -3,11 +3,7 @@
|
||||
* @remarks The result is cached for the revalidation period in seconds
|
||||
*/
|
||||
export default async function getTournaments(country: string) {
|
||||
const server =
|
||||
process.env.NODE_ENV === "production"
|
||||
? process.env.NEXT_PUBLIC_HOSTNAME
|
||||
: "http://localhost:3000";
|
||||
|
||||
const server = process.env.SERVER;
|
||||
const res = await fetch(`${server}/api/tournaments/${country}`, {
|
||||
next: { revalidate: 300 },
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user