fix
This commit is contained in:
@@ -13,7 +13,6 @@ services:
|
|||||||
- .env.docker
|
- .env.docker
|
||||||
volumes:
|
volumes:
|
||||||
- postgres-data:/var/lib/postgresql/data
|
- postgres-data:/var/lib/postgresql/data
|
||||||
- ./.docker-postgres-init:/docker-entrypoint-initdb.d
|
|
||||||
networks:
|
networks:
|
||||||
- app-network
|
- app-network
|
||||||
|
|
||||||
|
|||||||
@@ -23,10 +23,10 @@
|
|||||||
"@tanstack/react-devtools": "^0.7.6",
|
"@tanstack/react-devtools": "^0.7.6",
|
||||||
"@tanstack/react-query": "^5.66.0",
|
"@tanstack/react-query": "^5.66.0",
|
||||||
"@tanstack/react-query-devtools": "^5.66.0",
|
"@tanstack/react-query-devtools": "^5.66.0",
|
||||||
"@tanstack/react-router": "^1.130.12",
|
"@tanstack/react-router": "^1.143.6",
|
||||||
"@tanstack/react-router-devtools": "^1.130.13",
|
"@tanstack/react-router-devtools": "^1.143.6",
|
||||||
"@tanstack/react-router-with-query": "^1.130.12",
|
"@tanstack/react-router-ssr-query": "^1.143.6",
|
||||||
"@tanstack/react-start": "^1.132.2",
|
"@tanstack/react-start": "^1.143.6",
|
||||||
"@tanstack/react-virtual": "^3.13.12",
|
"@tanstack/react-virtual": "^3.13.12",
|
||||||
"@tiptap/pm": "^3.4.3",
|
"@tiptap/pm": "^3.4.3",
|
||||||
"@tiptap/react": "^3.4.3",
|
"@tiptap/react": "^3.4.3",
|
||||||
@@ -57,7 +57,6 @@
|
|||||||
"zustand": "^5.0.7"
|
"zustand": "^5.0.7"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@tanstack/react-router-ssr-query": "^1.132.2",
|
|
||||||
"@tanstack/router-plugin": "^1.132.2",
|
"@tanstack/router-plugin": "^1.132.2",
|
||||||
"@types/node": "^22.5.4",
|
"@types/node": "^22.5.4",
|
||||||
"@types/pg": "^8.15.5",
|
"@types/pg": "^8.15.5",
|
||||||
|
|||||||
@@ -223,6 +223,7 @@ const AuthedAdminTournamentsIdTeamsRoute =
|
|||||||
} as any)
|
} as any)
|
||||||
|
|
||||||
export interface FileRoutesByFullPath {
|
export interface FileRoutesByFullPath {
|
||||||
|
'/': typeof AuthedIndexRoute
|
||||||
'/login': typeof LoginRoute
|
'/login': typeof LoginRoute
|
||||||
'/logout': typeof LogoutRoute
|
'/logout': typeof LogoutRoute
|
||||||
'/refresh-session': typeof RefreshSessionRoute
|
'/refresh-session': typeof RefreshSessionRoute
|
||||||
@@ -231,7 +232,6 @@ export interface FileRoutesByFullPath {
|
|||||||
'/settings': typeof AuthedSettingsRoute
|
'/settings': typeof AuthedSettingsRoute
|
||||||
'/stats': typeof AuthedStatsRoute
|
'/stats': typeof AuthedStatsRoute
|
||||||
'/api/health': typeof ApiHealthRoute
|
'/api/health': typeof ApiHealthRoute
|
||||||
'/': typeof AuthedIndexRoute
|
|
||||||
'/admin/activities': typeof AuthedAdminActivitiesRoute
|
'/admin/activities': typeof AuthedAdminActivitiesRoute
|
||||||
'/admin/badges': typeof AuthedAdminBadgesRoute
|
'/admin/badges': typeof AuthedAdminBadgesRoute
|
||||||
'/admin/preview': typeof AuthedAdminPreviewRoute
|
'/admin/preview': typeof AuthedAdminPreviewRoute
|
||||||
@@ -249,13 +249,13 @@ export interface FileRoutesByFullPath {
|
|||||||
'/api/teams/upload-logo': typeof ApiTeamsUploadLogoRoute
|
'/api/teams/upload-logo': typeof ApiTeamsUploadLogoRoute
|
||||||
'/api/tournaments/upload-logo': typeof ApiTournamentsUploadLogoRoute
|
'/api/tournaments/upload-logo': typeof ApiTournamentsUploadLogoRoute
|
||||||
'/admin/': typeof AuthedAdminIndexRoute
|
'/admin/': typeof AuthedAdminIndexRoute
|
||||||
'/tournaments': typeof AuthedTournamentsIndexRoute
|
'/tournaments/': typeof AuthedTournamentsIndexRoute
|
||||||
'/tournaments/$id/bracket': typeof AuthedTournamentsIdBracketRoute
|
'/tournaments/$id/bracket': typeof AuthedTournamentsIdBracketRoute
|
||||||
'/admin/tournaments': typeof AuthedAdminTournamentsIndexRoute
|
'/admin/tournaments/': typeof AuthedAdminTournamentsIndexRoute
|
||||||
'/admin/tournaments/$id/teams': typeof AuthedAdminTournamentsIdTeamsRoute
|
'/admin/tournaments/$id/teams': typeof AuthedAdminTournamentsIdTeamsRoute
|
||||||
'/admin/tournaments/run/$id': typeof AuthedAdminTournamentsRunIdRoute
|
'/admin/tournaments/run/$id': typeof AuthedAdminTournamentsRunIdRoute
|
||||||
'/api/files/$collection/$recordId/$file': typeof ApiFilesCollectionRecordIdFileRoute
|
'/api/files/$collection/$recordId/$file': typeof ApiFilesCollectionRecordIdFileRoute
|
||||||
'/admin/tournaments/$id': typeof AuthedAdminTournamentsIdIndexRoute
|
'/admin/tournaments/$id/': typeof AuthedAdminTournamentsIdIndexRoute
|
||||||
}
|
}
|
||||||
export interface FileRoutesByTo {
|
export interface FileRoutesByTo {
|
||||||
'/login': typeof LoginRoute
|
'/login': typeof LoginRoute
|
||||||
@@ -331,6 +331,7 @@ export interface FileRoutesById {
|
|||||||
export interface FileRouteTypes {
|
export interface FileRouteTypes {
|
||||||
fileRoutesByFullPath: FileRoutesByFullPath
|
fileRoutesByFullPath: FileRoutesByFullPath
|
||||||
fullPaths:
|
fullPaths:
|
||||||
|
| '/'
|
||||||
| '/login'
|
| '/login'
|
||||||
| '/logout'
|
| '/logout'
|
||||||
| '/refresh-session'
|
| '/refresh-session'
|
||||||
@@ -339,7 +340,6 @@ export interface FileRouteTypes {
|
|||||||
| '/settings'
|
| '/settings'
|
||||||
| '/stats'
|
| '/stats'
|
||||||
| '/api/health'
|
| '/api/health'
|
||||||
| '/'
|
|
||||||
| '/admin/activities'
|
| '/admin/activities'
|
||||||
| '/admin/badges'
|
| '/admin/badges'
|
||||||
| '/admin/preview'
|
| '/admin/preview'
|
||||||
@@ -357,13 +357,13 @@ export interface FileRouteTypes {
|
|||||||
| '/api/teams/upload-logo'
|
| '/api/teams/upload-logo'
|
||||||
| '/api/tournaments/upload-logo'
|
| '/api/tournaments/upload-logo'
|
||||||
| '/admin/'
|
| '/admin/'
|
||||||
| '/tournaments'
|
| '/tournaments/'
|
||||||
| '/tournaments/$id/bracket'
|
| '/tournaments/$id/bracket'
|
||||||
| '/admin/tournaments'
|
| '/admin/tournaments/'
|
||||||
| '/admin/tournaments/$id/teams'
|
| '/admin/tournaments/$id/teams'
|
||||||
| '/admin/tournaments/run/$id'
|
| '/admin/tournaments/run/$id'
|
||||||
| '/api/files/$collection/$recordId/$file'
|
| '/api/files/$collection/$recordId/$file'
|
||||||
| '/admin/tournaments/$id'
|
| '/admin/tournaments/$id/'
|
||||||
fileRoutesByTo: FileRoutesByTo
|
fileRoutesByTo: FileRoutesByTo
|
||||||
to:
|
to:
|
||||||
| '/login'
|
| '/login'
|
||||||
@@ -481,7 +481,7 @@ declare module '@tanstack/react-router' {
|
|||||||
'/_authed': {
|
'/_authed': {
|
||||||
id: '/_authed'
|
id: '/_authed'
|
||||||
path: ''
|
path: ''
|
||||||
fullPath: ''
|
fullPath: '/'
|
||||||
preLoaderRoute: typeof AuthedRouteImport
|
preLoaderRoute: typeof AuthedRouteImport
|
||||||
parentRoute: typeof rootRouteImport
|
parentRoute: typeof rootRouteImport
|
||||||
}
|
}
|
||||||
@@ -530,7 +530,7 @@ declare module '@tanstack/react-router' {
|
|||||||
'/_authed/tournaments/': {
|
'/_authed/tournaments/': {
|
||||||
id: '/_authed/tournaments/'
|
id: '/_authed/tournaments/'
|
||||||
path: '/tournaments'
|
path: '/tournaments'
|
||||||
fullPath: '/tournaments'
|
fullPath: '/tournaments/'
|
||||||
preLoaderRoute: typeof AuthedTournamentsIndexRouteImport
|
preLoaderRoute: typeof AuthedTournamentsIndexRouteImport
|
||||||
parentRoute: typeof AuthedRoute
|
parentRoute: typeof AuthedRoute
|
||||||
}
|
}
|
||||||
@@ -656,7 +656,7 @@ declare module '@tanstack/react-router' {
|
|||||||
'/_authed/admin/tournaments/': {
|
'/_authed/admin/tournaments/': {
|
||||||
id: '/_authed/admin/tournaments/'
|
id: '/_authed/admin/tournaments/'
|
||||||
path: '/tournaments'
|
path: '/tournaments'
|
||||||
fullPath: '/admin/tournaments'
|
fullPath: '/admin/tournaments/'
|
||||||
preLoaderRoute: typeof AuthedAdminTournamentsIndexRouteImport
|
preLoaderRoute: typeof AuthedAdminTournamentsIndexRouteImport
|
||||||
parentRoute: typeof AuthedAdminRoute
|
parentRoute: typeof AuthedAdminRoute
|
||||||
}
|
}
|
||||||
@@ -670,7 +670,7 @@ declare module '@tanstack/react-router' {
|
|||||||
'/_authed/admin/tournaments/$id/': {
|
'/_authed/admin/tournaments/$id/': {
|
||||||
id: '/_authed/admin/tournaments/$id/'
|
id: '/_authed/admin/tournaments/$id/'
|
||||||
path: '/tournaments/$id'
|
path: '/tournaments/$id'
|
||||||
fullPath: '/admin/tournaments/$id'
|
fullPath: '/admin/tournaments/$id/'
|
||||||
preLoaderRoute: typeof AuthedAdminTournamentsIdIndexRouteImport
|
preLoaderRoute: typeof AuthedAdminTournamentsIdIndexRouteImport
|
||||||
parentRoute: typeof AuthedAdminRoute
|
parentRoute: typeof AuthedAdminRoute
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -4,10 +4,12 @@ import { getRequest } from "@tanstack/react-start/server";
|
|||||||
|
|
||||||
export const serverFnLoggingMiddleware = createMiddleware({
|
export const serverFnLoggingMiddleware = createMiddleware({
|
||||||
type: "function",
|
type: "function",
|
||||||
}).server(async ({ next, data, functionId, context }) => {
|
}).server(async ({ next, data, context }) => {
|
||||||
const request = getRequest();
|
const request = getRequest();
|
||||||
|
|
||||||
const serverFnName = functionId.split('--')[1]?.split('_')[0] || 'unknown';
|
const url = new URL(request.url);
|
||||||
|
const pathParts = url.pathname.split('/').filter(Boolean);
|
||||||
|
const serverFnName = pathParts[pathParts.length - 1] || 'unknown';
|
||||||
const userId = (context as any)?.metadata?.player_id || 'unknown';
|
const userId = (context as any)?.metadata?.player_id || 'unknown';
|
||||||
|
|
||||||
const startTime = Date.now();
|
const startTime = Date.now();
|
||||||
|
|||||||
Reference in New Issue
Block a user