Skip to content

Commit

Permalink
Fixing sonarqube
Browse files Browse the repository at this point in the history
  • Loading branch information
softwaremagico committed Apr 25, 2024
1 parent cf63abf commit 4d69b96
Show file tree
Hide file tree
Showing 8 changed files with 14 additions and 14 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
[![GitHub commit activity](https://img.shields.io/github/commit-activity/y/softwaremagico/KendoTournamentManager)](https://github.com/softwaremagico/KendoTournamentManager)
[![GitHub last commit](https://img.shields.io/github/last-commit/softwaremagico/KendoTournamentManager)](https://github.com/softwaremagico/KendoTournamentManager)
[![CircleCI](https://circleci.com/gh/softwaremagico/KendoTournamentManager.svg?style=shield)](https://circleci.com/gh/softwaremagico/KendoTournamentManager)
[![Time](https://img.shields.io/badge/development-599.5h-blueviolet.svg)]()
[![Time](https://img.shields.io/badge/development-600h-blueviolet.svg)]()

[![Powered by](https://img.shields.io/badge/powered%20by%20java-orange.svg?logo=OpenJDK&logoColor=white)]()
[![Vulnerabilities](https://sonarcloud.io/api/project_badges/measure?project=kendo-tournament-backend&metric=vulnerabilities)](https://sonarcloud.io/summary/new_code?id=kendo-tournament-backend)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,6 @@
.achievement-wall {
display: flex;
flex-wrap: wrap;
//background-color: #012f67;
//border: 7px #000000 solid;
//border-radius: 15px;
overflow-y: auto;
max-height: 230px;
padding: 10px;
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<div class="participant-picture">
<div (dblclick)="openImage()" *ngIf="participantPicture" class="container">
<img alt="Participant's Picture" class="picture" src="{{ participantPicture }}"/>
<img alt="Participant" class="picture" src="{{ participantPicture }}"/>
</div>
<div *ngIf="!participantPicture" [style]="circleStyle" class="container">
<span class="initials">{{this.participantInitials}}</span>
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<div class="content">
<div class="picture-container">
<img alt="Participant's Picture" class="picture" src="{{ participantPicture }}"/>
<img alt="Participant" class="picture" src="{{ participantPicture }}"/>
</div>
<div class="button-container" mat-dialog-actions>
<button (click)="closeDialog()" color="warn" mat-flat-button mat-raised-button type="button">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,11 +203,13 @@ export class TournamentBracketsEditorComponent implements OnChanges, OnInit, OnD
}

deleteLast(): void {
const lastGroup: Group = this.groups.filter((g: Group): boolean => {
return g.level === 0;
}).reduce((prev: Group, current: Group): Group => (prev.index > current.index) ?
prev : current);
this.deleteGroup(lastGroup);
if (this.groups.length > 0) {
const lastGroup: Group = this.groups.filter((g: Group): boolean => {
return g.level === 0;
}).reduce((prev: Group, current: Group): Group => (prev.index > current.index) ?
prev : current, this.groups[this.groups.length - 1]);
this.deleteGroup(lastGroup);
}
}

deleteGroup(group: Group | undefined | null): void {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,8 @@ export class ShiaijoComponent {

getLastGroup(): Group | undefined {
if (this.groups && this.groups.length > 0) {
return this.groups.reduce((group1: Group, group2: Group): Group => group1.index > group2.index ? group1 : group2);
return this.groups.reduce((group1: Group, group2: Group): Group => group1.index > group2.index ? group1 : group2,
this.groups[this.groups.length - 1]);
}
return undefined;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ <h1 mat-dialog-title>{{title}}</h1>
</ng-template>
</div>
<div *ngIf="participantPicture" class="picture-container">
<img alt="Participant's Picture" class="picture" src="{{ participantPicture }}"/>
<img alt="Participant" class="picture" src="{{ participantPicture }}"/>
<button (click)="deletePicture()" class="floating-button" color="warn" mat-flat-button mat-mini-fab
type="button">
<mat-icon>cancel</mat-icon>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,7 @@
[style.margin-top]="(getLinePosition()-10)+'px'"
class="name">
{{'nameExample' | translate}}</span>
<img *ngIf="image" alt="Image preview"
<img *ngIf="image" alt="Preview"
class="image-preview" src="{{ image }}"/>
<div *ngIf="!image" class="empty-image image-preview">
</div>
Expand Down

0 comments on commit 4d69b96

Please sign in to comment.