Results should not be stored
This commit is contained in:
parent
5ed7e82e51
commit
05802d7ba4
3 changed files with 3 additions and 3 deletions
|
@ -4,7 +4,7 @@ import {PlayerOO} from "@/holycow"
|
|||
|
||||
export default async function Page({params}) {
|
||||
const {telegramId} = await params
|
||||
const playerResponse = await fetch(`${process.env.BASE_URL}/api/results/telegram/${telegramId}`)
|
||||
const playerResponse = await fetch(`${process.env.BASE_URL}/api/results/telegram/${telegramId}`, {cache: "no-store"})
|
||||
const player: PlayerOO = await playerResponse.json()
|
||||
|
||||
return (
|
||||
|
|
|
@ -4,7 +4,7 @@ import {PlayerO} from "@/holycow"
|
|||
|
||||
export default async function Page({params}) {
|
||||
const {telegramId} = await params
|
||||
const playersResponse = await fetch(`${process.env.BASE_URL}/api/results/`)
|
||||
const playersResponse = await fetch(`${process.env.BASE_URL}/api/results/`, {cache: "no-store"})
|
||||
const players: PlayerO[] = await playersResponse.json()
|
||||
const playerA: PlayerO = players.find(p => p.telegram_id == telegramId)
|
||||
|
||||
|
|
|
@ -3,7 +3,7 @@ import {PlayerO} from "@/holycow"
|
|||
|
||||
|
||||
export default async function Page() {
|
||||
const resultsResponse = await fetch(`${process.env.BASE_URL}/api/results/`)
|
||||
const resultsResponse = await fetch(`${process.env.BASE_URL}/api/results/`, {cache: "no-store"})
|
||||
const results: PlayerO[] = await resultsResponse.json()
|
||||
const ratedPlayers = results.filter(p => p.human_score !== null).toSorted((a, b) => a.human_score - b.human_score).toReversed()
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue