fixL refresh 404 error

This commit is contained in:
hamster1963 2024-11-27 21:24:48 +08:00
parent 1e7e4c6678
commit e758ae137b

View File

@ -43,7 +43,7 @@ export default function ServerDetailClient({
} }
}; };
const { data: allFallbackData } = useSWRImmutable<ServerApi>( const { data: allFallbackData, isLoading } = useSWRImmutable<ServerApi>(
"/api/server", "/api/server",
nezhaFetcher, nezhaFetcher,
); );
@ -51,7 +51,7 @@ export default function ServerDetailClient({
(item) => item.id === server_id, (item) => item.id === server_id,
); );
if (!fallbackData) { if (!fallbackData && !isLoading) {
notFound(); notFound();
} }