Update worldmap.js

This commit is contained in:
Dave Conway-Jones 2021-10-22 23:40:32 +01:00
parent 8cdd679e18
commit cdcccb296b
No known key found for this signature in database
GPG Key ID: 88BA2B8A411BE9FF

View File

@ -1784,13 +1784,13 @@ function setMarker(data) {
var reft = new RegExp('feet|ft','i');
var refm = new RegExp('metres|m','i');
if ( reft.test(""+data.alt) ) {
data.alt = (parseFloat(data.alt)).toFixed(2) + " ft";
data.alt = +(parseFloat(data.alt)).toFixed(2) + " ft";
}
else if ( refm.test(""+data.alt) ) {
data.alt = (parseFloat(data.alt)).toFixed(2) + " m";
data.alt = +(parseFloat(data.alt)).toFixed(2) + " m";
}
else {
data.alt = (parseFloat(data.alt)).toFixed(2);
data.alt = +(parseFloat(data.alt)).toFixed(2);
}
}