cleanup and remove web worker tests
All checks were successful
Deploy SSR / deploy (push) Successful in 1m16s

This commit is contained in:
Lee
2024-09-13 20:04:04 +01:00
parent bc2ddfa3a3
commit 37e2b305ff
41 changed files with 73 additions and 69 deletions

View File

@ -1,5 +1,5 @@
import { scoresaberFetcher } from "@/common/data-fetcher/impl/scoresaber";
import { ScoreSort } from "@/common/data-fetcher/sort";
import { scoresaberService } from "@/common/service/impl/scoresaber";
import { ScoreSort } from "@/common/service/score-sort";
import { formatNumberWithCommas } from "@/common/number-utils";
import PlayerData from "@/components/player/player-data";
import { format } from "@formkit/tempo";
@ -16,7 +16,7 @@ export async function generateMetadata({
params: { slug },
}: Props): Promise<Metadata> {
const id = slug[0]; // The players id
const player = await scoresaberFetcher.lookupPlayer(id, false);
const player = await scoresaberService.lookupPlayer(id, false);
if (player === undefined) {
return {
title: `Unknown Player`,
@ -44,8 +44,8 @@ export default async function Search({ params: { slug } }: Props) {
const id = slug[0]; // The players id
const sort: ScoreSort = (slug[1] as ScoreSort) || "recent"; // The sorting method
const page = parseInt(slug[2]) || 1; // The page number
const player = await scoresaberFetcher.lookupPlayer(id, false);
const scores = await scoresaberFetcher.lookupPlayerScores({
const player = await scoresaberService.lookupPlayer(id, false);
const scores = await scoresaberService.lookupPlayerScores({
playerId: id,
sort,
page,