Skip to content

Commit ba52634

Browse files
Try to fix lint errors
1 parent d6fc270 commit ba52634

File tree

2 files changed

+6
-9
lines changed

2 files changed

+6
-9
lines changed

Angular/src/app/app.component.ts

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ export class AppComponent {
2828

2929
ngOnInit(): void {
3030
this.generateHexCodes();
31-
this.fetchColorsForPage();
31+
void this.fetchColorsForPage();
3232
}
3333

3434
generateHexCodes(): void {
@@ -74,5 +74,4 @@ export class AppComponent {
7474
this.pageSize = val;
7575
void this.fetchColorsForPage();
7676
}
77-
7877
}

Angular/src/app/app.service.ts

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -46,16 +46,14 @@ export class ColorService {
4646
.pipe(
4747
catchError((error: any) => throwError(() => new Error(`Error fetching color: ${error.message || error}`))),
4848
)
49-
.pipe(map((data: any) => {
50-
return {
51-
name: data.name.value,
52-
image: data.image.bare,
53-
}
54-
}));
49+
.pipe(map((data: any) => ({
50+
name: data.name.value,
51+
image: data.image.bare,
52+
})));
5553
}
5654
}
5755

5856
export interface Color {
5957
image: string;
6058
name: string;
61-
}
59+
}

0 commit comments

Comments
 (0)