stats/runners/laptime feature/190-runners_laptime #191

Merged
niggl merged 36 commits from feature/190-runners_laptime into dev 2021-04-07 17:16:35 +00:00
Showing only changes of commit dcdbdd15ac - Show all commits

View File

@ -51,6 +51,9 @@ export abstract class RunnerGroup {
*/
@IsInt()
public get distance(): number {
if (!this.runners || this.runners.length == 0) {
return 0;
}
return this.runners.reduce((sum, current) => sum + current.distance, 0);
}