diff --git a/ExpressAPI/src/routes/ExerciceRoutes.ts b/ExpressAPI/src/routes/ExerciceRoutes.ts index 07239d0e90ad4a2f25be99b7e2788924b65b6bc2..d2977dbb253eaa10e67090ef7e3439d5cc0df819 100644 --- a/ExpressAPI/src/routes/ExerciceRoutes.ts +++ b/ExpressAPI/src/routes/ExerciceRoutes.ts @@ -136,11 +136,11 @@ class ExerciceRoutes implements RoutesManager { } private async getEnonce(req: ApiRequest, res: express.Response) { - const repoTree: Array<GitlabTreeFile> = await GitlabManager.getRepositoryTree(req.boundParams.exercice.gitlabId); + const repoTree: Array<GitlabTreeFile> = await GitlabManager.getRepositoryTree(req.boundParams.exercice.enonce.gitlabId); let enonceYamlFile: GitlabFile; let immutableFiles: Array<GitlabFile> = await Promise.all(Config.enonce.baseFiles.map(async (baseFile: string) => { - let file = await GitlabManager.getFile(req.boundParams.exercice.gitlabId, baseFile); + let file = await GitlabManager.getFile(req.boundParams.exercice.enonce.gitlabId, baseFile); if ( baseFile === Config.enonce.filename ) { enonceYamlFile = file; @@ -157,7 +157,7 @@ class ExerciceRoutes implements RoutesManager { if ( gitlabTreeFile.type == GitlabTreeFileType.BLOB ) { for ( const immutablePath of immutablePaths ) { if ( gitlabTreeFile.path.startsWith(immutablePath) ) { - immutableFiles.push(await GitlabManager.getFile(req.boundParams.exercice.gitlabId, gitlabTreeFile.path)); + immutableFiles.push(await GitlabManager.getFile(req.boundParams.exercice.enonce.gitlabId, gitlabTreeFile.path)); break; } }