diff --git a/metar.html b/metar.html index 9aca05d..3813440 100644 --- a/metar.html +++ b/metar.html @@ -743,7 +743,11 @@ while(index < parts.length && !preambleEnded) { const part = parts[index]; - if (part.length === 4 && part.match(/^[A-Z][A-Z0-9]{3}$/)) { + if (part === 'AUTO') { + airportTimeAutoRaw.push(part); + airportTimeAutoDecoded.push("AUTO: Fully automated observation"); + index++; + } else if (part.length === 4 && part.match(/^[A-Z][A-Z0-9]{3}$/)) { airportTimeAutoRaw.push(part); airportTimeAutoDecoded.push(decodeAirport(part, metarString)); index++; @@ -751,10 +755,6 @@ airportTimeAutoRaw.push(part); airportTimeAutoDecoded.push(decodeTime(part)); index++; - } else if (part === 'AUTO') { - airportTimeAutoRaw.push(part); - airportTimeAutoDecoded.push("AUTO: Fully automated observation"); - index++; } else if (part.match(/^CC[A-Z]$/)) { airportTimeAutoRaw.push(part); airportTimeAutoDecoded.push(`${part}: Correction to the report`);