v{APP_VERSION}
diff --git a/apps/clients/chooser/src/routes/main-page.tsx b/apps/clients/chooser/src/routes/main-page.tsx
index 838e1ee..3c51170 100644
--- a/apps/clients/chooser/src/routes/main-page.tsx
+++ b/apps/clients/chooser/src/routes/main-page.tsx
@@ -3,9 +3,9 @@ import { useServerSetting } from "@/context/server-setting";
import { motion } from "framer-motion";
export default function MainPage() {
- const { canAttend } = useServerSetting();
+ const { canVote } = useServerSetting();
- if (!canAttend)
+ if (!canVote)
return (
- Belum Bisa Absen!
+ Belum Bisa Memilih!
);
diff --git a/apps/clients/chooser/tsconfig.app.json b/apps/clients/chooser/tsconfig.app.json
index 47c9833..c1adde8 100644
--- a/apps/clients/chooser/tsconfig.app.json
+++ b/apps/clients/chooser/tsconfig.app.json
@@ -24,6 +24,7 @@
"noFallthroughCasesInSwitch": true,
/* Absolute Import */
+ "baseUrl": "./",
"paths": {
"@/*": ["src/*"]
}
diff --git a/packages/api/src/router/client.ts b/packages/api/src/router/client.ts
index a6dd3a3..95153f5 100644
--- a/packages/api/src/router/client.ts
+++ b/packages/api/src/router/client.ts
@@ -1,7 +1,7 @@
import type { TRPCRouterRecord } from "@trpc/server";
import { TRPCError } from "@trpc/server";
-import { and, eq, not, schema, sql } from "@sora-vp/db";
+import { eq, schema, sql } from "@sora-vp/db";
import settings, { canAttendNow } from "@sora-vp/settings";
import { participant } from "@sora-vp/validators";
@@ -28,8 +28,14 @@ export const clientRouter = {
SELECT * FROM ${schema.participants} WHERE ${schema.participants.qrId} = ${input} FOR UPDATE
`);
- const participantContainer = participantRawQuery.at(0)!;
- const participant = participantContainer.at(0)!;
+ const participantContainer = participantRawQuery.at(0) as unknown as {
+ name: string;
+ already_attended: boolean;
+ qr_id: string;
+ sub_part: string;
+ }[];
+
+ const participant = participantContainer.at(0);
if (!participant)
throw new TRPCError({