diff --git a/src/db/schema/strike.ts b/src/db/schema/strike.ts index 7884bcb..14df30e 100644 --- a/src/db/schema/strike.ts +++ b/src/db/schema/strike.ts @@ -3,7 +3,6 @@ import { strikeReason } from '@db/schema/strikeReason.ts'; import type { MySql2Database } from 'drizzle-orm/mysql2'; import { eq } from 'drizzle-orm'; import { report } from '@db/schema/report.ts'; -import { reportStatus } from '@db/schema/reportStatus.ts'; type Database = MySql2Database<{ strike: typeof strike }>; @@ -52,6 +51,6 @@ export async function getStrikesByTeamId(db: Database, values: GetStrikesByTeamI }) .from(strike) .innerJoin(strikeReason, eq(strike.strikeReasonId, strikeReason.id)) - .innerJoin(report, eq(reportStatus.reportId, report.id)) + .innerJoin(report, eq(strike.reportId, report.id)) .where(eq(report.reportedTeamId, values.teamId)); }