reactions, match sse, etc
This commit is contained in:
@@ -7,7 +7,6 @@ import { Match } from "@/features/matches/types";
|
||||
export function createTeamsService(pb: PocketBase) {
|
||||
return {
|
||||
async getTeamInfo(id: string): Promise<TeamInfo> {
|
||||
logger.info("PocketBase | Getting team info", id);
|
||||
const result = await pb.collection("teams").getOne(id, {
|
||||
fields: "id,name,primary_color,accent_color,logo",
|
||||
expand: "players"
|
||||
@@ -25,7 +24,6 @@ export function createTeamsService(pb: PocketBase) {
|
||||
},
|
||||
|
||||
async getTeam(id: string): Promise<Team | null> {
|
||||
logger.info("PocketBase | Getting team", id);
|
||||
const result = await pb.collection("teams").getOne(id, {
|
||||
expand: "players, tournaments",
|
||||
});
|
||||
@@ -84,7 +82,6 @@ export function createTeamsService(pb: PocketBase) {
|
||||
},
|
||||
|
||||
async getTeamStats(id: string): Promise<TeamStats | null> {
|
||||
logger.info("PocketBase | Getting team stats", id);
|
||||
try {
|
||||
const result = await pb.collection("team_stats").getFirstListItem(`team_id="${id}"`);
|
||||
return result as unknown as TeamStats;
|
||||
|
||||
Reference in New Issue
Block a user