chore: Tweaks

This commit is contained in:
Tibo De Peuter 2025-05-19 19:07:59 +02:00
parent fc10fb96d6
commit bed875c8d8
Signed by: tdpeuter
GPG key ID: 38297DE43F75FFE2
2 changed files with 3 additions and 2 deletions

View file

@ -1,4 +1,4 @@
import { assign, Collection, MikroORM } from '@mikro-orm/core';
import { Collection, MikroORM } from '@mikro-orm/core';
import { forkEntityManager } from '../src/orm';
import { makeTestStudents } from '../tests/test_assets/users/students.testdata';
import { makeTestTeachers } from '../tests/test_assets/users/teachers.testdata';

View file

@ -10,6 +10,7 @@
import type { ClassesResponse } from "@/controllers/classes.ts";
import type { AssignmentDTO } from "@dwengo-1/common/interfaces/assignment";
import { useCreateAssignmentMutation } from "@/queries/assignments.ts";
import { AccountType } from '@dwengo-1/common/util/account-types';
const route = useRoute();
const router = useRouter();
@ -18,7 +19,7 @@
const username = ref<string>("");
onMounted(async () => {
if (role.value === "student") {
if (role.value === AccountType.Student) {
await router.push("/user");
}
const user = await auth.loadUser();