Skip to content

Commit

Permalink
special lastname handling
Browse files Browse the repository at this point in the history
  • Loading branch information
nimarion committed Feb 21, 2024
1 parent a40fcc8 commit c0217a9
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/athletes/athletes.service.ts
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,9 @@ export class AthletesService {
.toLowerCase()
.split(' ')
.map((s) => s[0].toUpperCase() + s.slice(1))
.join(' ');
.join(' ')
// if lastname contains "-" like Skupin-alfa -> capitalize both parts
.split('-').map((s) => s[0].toUpperCase() + s.slice(1)).join('-');

const worldRankingSex =
response.getSingleCompetitor.worldRankings.best.length > 0
Expand Down

0 comments on commit c0217a9

Please sign in to comment.