diff --git a/src/app/components/editor/editor.component.ts b/src/app/components/editor/editor.component.ts index ce32fd2..c874d27 100644 --- a/src/app/components/editor/editor.component.ts +++ b/src/app/components/editor/editor.component.ts @@ -160,7 +160,7 @@ export class EditorComponent { constructor( private router: Router, - private codeExecutionService: BackendService + private backendService: BackendService ) {} // Efface le contenu de l'éditeur @@ -169,7 +169,7 @@ export class EditorComponent { } async onCreateRoomButtonClicked() { - const idRoom = await this.codeExecutionService.createRoom(); + const idRoom = await this.backendService.createRoom(); console.log(idRoom); this.router.navigate([`./editor-live/${idRoom}`]); } @@ -178,7 +178,7 @@ export class EditorComponent { // Le code à exécuter est le contenu de l'éditeur const codeToExecute = this.editorContent; - this.codeExecutionService.executeCode( + this.backendService.executeCode( codeToExecute, this.selectedLanguage.name );