diff --git a/themes/intotheeast/templates/trip.html.twig b/themes/intotheeast/templates/trip.html.twig index d0c4493..8f12790 100644 --- a/themes/intotheeast/templates/trip.html.twig +++ b/themes/intotheeast/templates/trip.html.twig @@ -449,8 +449,8 @@ function parseGpxFiles(urls, callback) { if (!isNaN(p0.ele) && !isNaN(p1.ele)) { var dEle = p1.ele - p0.ele; - if (dEle > 1) totalEleGain += dEle - 1; - if (dEle < -1) totalEleLoss += (-dEle) - 1; + if (dEle > 0) totalEleGain += dEle; + if (dEle < 0) totalEleLoss += (-dEle); if (isNaN(globalHighest) || p1.ele > globalHighest) globalHighest = p1.ele; if (isNaN(globalLowest) || p1.ele < globalLowest) globalLowest = p1.ele; }