Fix Bug 2121: NG-UI uses unmaintained Chokidar version
- Upgraded Angular from 11 to 14 version to remove chokidar
unmaintained version.
- Changed linting tool tslint to eslint for angular 14 as tslint
is depreacted after angular 12
- Resolved linting issues from code
Change-Id: I00e908ab651db0f080e0d18a9d1c9711f4e36b91
Signed-off-by: SANDHYA.JS <sandhya.j@tataelxsi.co.in>
diff --git a/src/app/sdn-controller/SDNControllerComponent.ts b/src/app/sdn-controller/SDNControllerComponent.ts
index 661882c..247553a 100644
--- a/src/app/sdn-controller/SDNControllerComponent.ts
+++ b/src/app/sdn-controller/SDNControllerComponent.ts
@@ -49,7 +49,9 @@
/** Return to list NS Package List */
public redirectToList(getURL: string): void {
if (getURL === '/sdn') {
- this.router.navigate(['/sdn/details']).catch();
+ this.router.navigate(['/sdn/details']).catch((): void => {
+ // Catch Navigation Error
+ });
}
}
}
diff --git a/src/app/sdn-controller/SDNControllerModule.ts b/src/app/sdn-controller/SDNControllerModule.ts
index 6da4a5c..9b2f523 100644
--- a/src/app/sdn-controller/SDNControllerModule.ts
+++ b/src/app/sdn-controller/SDNControllerModule.ts
@@ -68,7 +68,6 @@
PagePerRowModule, LoaderModule, PageReloadModule],
declarations: [SDNControllerComponent, SDNControllerDetailsComponent, SDNControllerInfoComponent, NewSDNControllerComponent],
providers: [DataService],
- entryComponents: [SDNControllerInfoComponent, NewSDNControllerComponent],
schemas: [CUSTOM_ELEMENTS_SCHEMA]
})
/** Exporting a class @exports SDNControllerModule */
@@ -76,7 +75,7 @@
/**
* Lifecyle Hooks the trigger before component is instantiate
*/
- public ngOnInit(): void {
- //Empty Class
- }
+ constructor() {
+ //Empty
+ }
}
diff --git a/src/app/sdn-controller/sdn-controller-details/SDNControllerDetailsComponent.ts b/src/app/sdn-controller/sdn-controller-details/SDNControllerDetailsComponent.ts
index 589f13e..ef2f350 100644
--- a/src/app/sdn-controller/sdn-controller-details/SDNControllerDetailsComponent.ts
+++ b/src/app/sdn-controller/sdn-controller-details/SDNControllerDetailsComponent.ts
@@ -206,12 +206,15 @@
/** Compose new SDN Controller @public */
public composeSDN(): void {
+ // eslint-disable-next-line security/detect-non-literal-fs-filename
const modalRef: NgbModalRef = this.modalService.open(NewSDNControllerComponent, { backdrop: 'static' });
modalRef.result.then((result: MODALCLOSERESPONSEDATA) => {
if (result) {
this.sharedService.callData();
}
- }).catch();
+ }).catch((): void => {
+ // Catch Navigation Error
+ });
}
/**
@@ -237,11 +240,12 @@
}
this.dataSource.load(this.sdnData).then((data: {}) => {
this.isLoadingResults = false;
- }).catch();
+ }).catch((): void => {
+ // Catch Navigation Error
+ });
}, (error: ERRORDATA) => {
this.restService.handleError(error, 'get');
this.isLoadingResults = false;
});
}
-
}