mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-08-22 19:16:09 -05:00
closes #207 fallback blocking
This commit is contained in:
@@ -1,3 +1,3 @@
|
||||
.next
|
||||
prisma/migrations
|
||||
locales/**/*.js
|
||||
locales/**/*
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Als .png herunterladen",
|
||||
"Download as .json": "Als .json herunterladen",
|
||||
"Load from .json": "Von .json laden",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "Waffe",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "Name",
|
||||
"X Power": "X-Power",
|
||||
"Mode": "Modus",
|
||||
"Weapon": "Waffe",
|
||||
"Month": "Monat",
|
||||
"Year": "Jahr",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "Stick",
|
||||
"Motion": "Bewegungssteuerung",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Λήψη ως .png",
|
||||
"Download as .json": "Λήψη ως .json",
|
||||
"Load from .json": "Άνοιγμα από .json",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "Όπλο",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "Όνομα",
|
||||
"X Power": "X Power",
|
||||
"Mode": "Mode",
|
||||
"Weapon": "Όπλο",
|
||||
"Month": "Μήνας",
|
||||
"Year": "Έτος",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "Stick",
|
||||
"Motion": "Motion",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Download as .png",
|
||||
"Download as .json": "Download as .json",
|
||||
"Load from .json": "Load from .json",
|
||||
"Date": "Date",
|
||||
"Power": "Power",
|
||||
"Weapon": "Weapon",
|
||||
"Mate": "Mate",
|
||||
"Mate's weapon": "Mate's weapon",
|
||||
"Name": "Name",
|
||||
"X Power": "X Power",
|
||||
"Mode": "Mode",
|
||||
"Weapon": "Weapon",
|
||||
"Month": "Month",
|
||||
"Year": "Year",
|
||||
"Date": "Date",
|
||||
"Power": "Power",
|
||||
"Mate": "Mate",
|
||||
"Mate's weapon": "Mate's weapon",
|
||||
"Stick": "Stick",
|
||||
"Motion": "Motion",
|
||||
"View results": "View results",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Descargar como .png",
|
||||
"Download as .json": "Descargar como .json",
|
||||
"Load from .json": "Cargar desde .json",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "Arma",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "Nombre",
|
||||
"X Power": "Energía X",
|
||||
"Mode": "Modo",
|
||||
"Weapon": "Arma",
|
||||
"Month": "Mes",
|
||||
"Year": "Año",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "Stick",
|
||||
"Motion": "Giroscopio",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Télécharger en tant que .png",
|
||||
"Download as .json": "Télécharger en tant que .json",
|
||||
"Load from .json": "Charger depuis .json",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "Arme",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "Nom",
|
||||
"X Power": "X Puissance",
|
||||
"Mode": "Mode",
|
||||
"Weapon": "Arme",
|
||||
"Month": "Mois",
|
||||
"Year": "Année",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "Joysticks",
|
||||
"Motion": "Gyroscope",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Scarica come .png",
|
||||
"Download as .json": "Scarica come .json",
|
||||
"Load from .json": "Carica da .json",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "Arma",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "Nome",
|
||||
"X Power": "Energia Rango X",
|
||||
"Mode": "Modalità",
|
||||
"Weapon": "Arma",
|
||||
"Month": "Mese",
|
||||
"Year": "Anno",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "Stick",
|
||||
"Motion": "Sensori",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "",
|
||||
"Download as .json": "",
|
||||
"Load from .json": "",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "",
|
||||
"X Power": "",
|
||||
"Mode": "",
|
||||
"Weapon": "",
|
||||
"Month": "",
|
||||
"Year": "",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "",
|
||||
"Motion": "",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": ".png 으로 다운로드",
|
||||
"Download as .json": ".json 으로 다운로드",
|
||||
"Load from .json": ".json 에서 로드",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "무기",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "이름",
|
||||
"X Power": "X 파워",
|
||||
"Mode": "모드",
|
||||
"Weapon": "무기",
|
||||
"Month": "달",
|
||||
"Year": "년",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "스틱",
|
||||
"Motion": "모션 / 자이로",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "",
|
||||
"Download as .json": "",
|
||||
"Load from .json": "",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "",
|
||||
"X Power": "",
|
||||
"Mode": "",
|
||||
"Weapon": "",
|
||||
"Month": "",
|
||||
"Year": "",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "",
|
||||
"Motion": "",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Baixar como .png",
|
||||
"Download as .json": "Baixar como .json",
|
||||
"Load from .json": "Carregar .json",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "Arma",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "Nome",
|
||||
"X Power": "X Power",
|
||||
"Mode": "Modo",
|
||||
"Weapon": "Arma",
|
||||
"Month": "Mês",
|
||||
"Year": "Ano",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "Stick",
|
||||
"Motion": "Motion",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "",
|
||||
"Download as .json": "",
|
||||
"Load from .json": "",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "",
|
||||
"X Power": "",
|
||||
"Mode": "",
|
||||
"Weapon": "",
|
||||
"Month": "",
|
||||
"Year": "",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "",
|
||||
"Motion": "",
|
||||
"View results": "",
|
||||
|
||||
@@ -49,16 +49,16 @@
|
||||
"Download as .png": "Ladda ner som .png",
|
||||
"Download as .json": "Ladda ner som .json",
|
||||
"Load from .json": "Ladda från .json",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Weapon": "Vapen",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Name": "Namn",
|
||||
"X Power": "X-Poäng",
|
||||
"Mode": "Spelläge",
|
||||
"Weapon": "Vapen",
|
||||
"Month": "Månad",
|
||||
"Year": "År",
|
||||
"Date": "",
|
||||
"Power": "",
|
||||
"Mate": "",
|
||||
"Mate's weapon": "",
|
||||
"Stick": "Stick",
|
||||
"Motion": "Motion",
|
||||
"View results": "",
|
||||
|
||||
@@ -44,7 +44,7 @@ const ProfilePage = (props: Props) => {
|
||||
{ initialData: props.user }
|
||||
);
|
||||
|
||||
const user = data ? data : props.user;
|
||||
const user = data ? data : props.user!;
|
||||
|
||||
const { data: builds, weaponCounts, setWeapon, buildCount } = useBuildsByUser(
|
||||
user?.id
|
||||
@@ -52,10 +52,6 @@ const ProfilePage = (props: Props) => {
|
||||
|
||||
const { i18n } = useLingui();
|
||||
|
||||
// same as router.isFallback
|
||||
// TODO: return spinner
|
||||
if (!user) return null;
|
||||
|
||||
const canPostBuilds = () => {
|
||||
if (loggedInUser?.id !== user.id) return false;
|
||||
if (buildCount >= 100 && user.discordId !== GANBA_DISCORD_ID) return false;
|
||||
@@ -172,7 +168,7 @@ export const getStaticPaths: GetStaticPaths = async () => {
|
||||
paths: users.map((u) => ({
|
||||
params: { identifier: u.profile?.customUrlPath ?? u.discordId },
|
||||
})),
|
||||
fallback: true,
|
||||
fallback: "blocking",
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user