From 8d1bb46e281a513310985960a284b97b784e5799 Mon Sep 17 00:00:00 2001 From: Ole Vester Date: Fri, 29 Nov 2024 18:30:26 +0100 Subject: [PATCH] Migrate standard-competencies-admin-import to use inject() --- ...n-import-standardized-competencies.component.ts | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/main/webapp/app/admin/standardized-competencies/import/admin-import-standardized-competencies.component.ts b/src/main/webapp/app/admin/standardized-competencies/import/admin-import-standardized-competencies.component.ts index 3cc041859bbe..1c87f12ccc31 100644 --- a/src/main/webapp/app/admin/standardized-competencies/import/admin-import-standardized-competencies.component.ts +++ b/src/main/webapp/app/admin/standardized-competencies/import/admin-import-standardized-competencies.component.ts @@ -1,4 +1,4 @@ -import { Component } from '@angular/core'; +import { Component, inject } from '@angular/core'; import { faBan, faChevronRight, faFileImport, faQuestionCircle } from '@fortawesome/free-solid-svg-icons'; import { KnowledgeAreaDTO, @@ -84,12 +84,12 @@ export class AdminImportStandardizedCompetenciesComponent { } \`\`\``; - public constructor( - private alertService: AlertService, - private adminStandardizedCompetencyService: AdminStandardizedCompetencyService, - private activatedRoute: ActivatedRoute, - private router: Router, - ) {} + private alertService = inject(AlertService); + private adminStandardizedCompetencyService = inject(AdminStandardizedCompetencyService); + private activatedRoute = inject(ActivatedRoute); + private router = inject(Router); + + public constructor() {} /** * Verifies the file (only .json, smaller than 20 MB) and then tries to read the importData from it