type audit script, fix misclassified activities, alpineski excluded from ascent

This commit is contained in:
Vincent van der Wal
2026-07-22 17:24:38 +02:00
parent 512860c863
commit c4512d3550
3 changed files with 157 additions and 2 deletions
+8 -2
View File
@@ -1,7 +1,13 @@
// Lift-assisted downhill types: their recorded elevation gain comes from
// lifts, so it doesn't count toward ascent totals. Touring variants
// ("ski touring", "backcountry ski") earn their metres and do count.
export const LIFT_ASSISTED_TYPES = ['ski', 'alpine ski', 'downhill ski', 'snowboard'];
// ("skitour", "backcountry ski", "langlauf") earn their metres and do count.
export const LIFT_ASSISTED_TYPES = [
'ski',
'alpine ski',
'alpineski',
'downhill ski',
'snowboard'
];
export function countsTowardAscent(type: string): boolean {
return !LIFT_ASSISTED_TYPES.includes(type.toLowerCase().trim());