import type { Graduation } from "./graduation-common.ts"; import { Student } from "./student-common.ts"; import { fetchStudentsMock as fetchStudents, fetchGraduationMock } from "./mock.ts"; declare module "./student-common.ts" { interface Student { getGraduation(): Promise; getIconUrl(): Promise; } } Student.prototype.getGraduation = function () { return fetchGraduationMock(this); }; Student.prototype.getIconUrl = async function () { return ""; }; async function fetchStudent(idFilter?: number, nameFilter?: string) { const students = await fetchStudents(idFilter, nameFilter); return students[0]; } export { Student, fetchStudents, fetchStudent };