Skip to content

Commit

Permalink
Fix prettier warnings
Browse files Browse the repository at this point in the history
  • Loading branch information
Yamaguchi committed Mar 18, 2024
1 parent d3c72c7 commit 06d4011
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 7 deletions.
4 changes: 1 addition & 3 deletions backend/actions/color_list.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,7 @@ app.get('/api/colors', async (req, res) => {
console.log(colors);
res.json({ colors: colors });
} catch (err) {
logger.error(
`Error retrieving colors. Error Message - ${err.message}`
);
logger.error(`Error retrieving colors. Error Message - ${err.message}`);
res.status(500).send(`Error Retrieving Blocks`);
}
});
5 changes: 4 additions & 1 deletion frontend/src/app/colors/colors.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ <h3 id="color-header-text">Colors</h3>
<ion-col size="8" class="pt-10">COLOR ID</ion-col>
<ion-col size="4" class="pt-10">LATEST USED BLOCK</ion-col>
</ion-row>
<ion-row class="text-color table-border-bottom" *ngFor="let color of colors">
<ion-row
class="text-color table-border-bottom"
*ngFor="let color of colors"
>
<ion-col
size="8"
(click)="goToColorPage(color[0])"
Expand Down
7 changes: 4 additions & 3 deletions frontend/src/app/colors/colors.page.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,16 +28,17 @@ export class ColorsPage implements OnInit {
) {}

ngOnInit() {
this.lastSeenColorId = this.activatedRoute.snapshot.paramMap.get('lastSeenColorId') || '';
this.lastSeenColorId =
this.activatedRoute.snapshot.paramMap.get('lastSeenColorId') || '';
this.getColorsInfo();
}

getColorsInfo() {
this.resetError();
this.backendService.getColors(this.lastSeenColorId).subscribe(
data => {
this.colors = this.colors.concat(data["colors"]);
this.lastSeenColorId = data["colors"][data["colors"].length - 1][0];
this.colors = this.colors.concat(data['colors']);
this.lastSeenColorId = data['colors'][data['colors'].length - 1][0];
},
err => {
console.log(err);
Expand Down

0 comments on commit 06d4011

Please sign in to comment.