Fix: don't show maxstay=30 days in velopark, this is actually 'unknown'

This commit is contained in:
Pieter Vander Vennet 2024-11-08 22:22:03 +01:00
parent f1106ad4a8
commit d2237cf26c
2 changed files with 14 additions and 7 deletions

View file

@ -371,6 +371,10 @@ export default class LinkedDataLoader {
const match = maxstay.match(/P([0-9]+)D/)
if (match) {
const days = Number(match[1])
if(days === 30){
// 30 is the default which is set if velopark didn't know the actual value
return undefined
}
if (days === 1) {
return "1 day"
}