Skip to content

Commit

Permalink
fix: person photo
Browse files Browse the repository at this point in the history
  • Loading branch information
ikit committed Feb 13, 2022
1 parent e8485e9 commit 2f8dc55
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions absg-core/src/entities/Person.ts
Original file line number Diff line number Diff line change
Expand Up @@ -81,13 +81,10 @@ export class Person {
if (Array.isArray(this.trombis) && this.trombis.length > 0) {
let lastPhoto = this.trombis[0];
for (const p of this.trombis) {

if (p.year > year) {
break;
}
if (p.year >= lastPhoto.year) {
lastPhoto = p;
}
lastPhoto = p;
}
return lastPhoto;
}
Expand Down

0 comments on commit 2f8dc55

Please sign in to comment.