Fix POTA regex

这个提交包含在:
Robert Sammelson 2023-11-11 01:25:21 -05:00
父节点 c5f9809d73
当前提交 15f52f99ca
找不到此签名对应的密钥
GPG 密钥 ID: BEA2C00D29709D51

查看文件

@ -164,13 +164,13 @@ function handleInput() {
qsotime = qsotime.slice(0, -2) + item; qsotime = qsotime.slice(0, -2) + item;
} else if ( } else if (
item.match( item.match(
/^[A-Z0-9]{1,3}\/[A-Z]{2}-\d{3}|[AENOS]*[FNSUACA]-\d{3}|(?!.*FF)[A-Z0-9]{1,3}-\d{4}|[A-Z0-9]{1,3}[F]{2}-\d{4}$/i /^[A-Z0-9]{1,3}\/[A-Z]{2}-\d{3}|[AENOS]*[FNSUACA]-\d{3}|(?!.*FF)[A-Z0-9]{1,3}-\d{4,5}|[A-Z0-9]{1,3}[F]{2}-\d{4}$/i
) )
) { ) {
sotaWwff = item.toUpperCase(); sotaWwff = item.toUpperCase();
} else if ( } else if (
item.match( item.match(
/([a-zA-Z0-9]{1,3}[0123456789][a-zA-Z0-9]{0,3}[a-zA-Z])|.*\/([a-zA-Z0-9]{1,3}[0123456789][a-zA-Z0-9]{0,3}[a-zA-Z])|([a-zA-Z0-9]{1,3}[0123456789][a-zA-Z0-9]{0,3}[a-zA-Z])\/.*/ /([a-zA-Z0-9]{1,3}[0-9][a-zA-Z0-9]{0,3}[a-zA-Z])|.*\/([a-zA-Z0-9]{1,3}[0-9][a-zA-Z0-9]{0,3}[a-zA-Z])|([a-zA-Z0-9]{1,3}[0-9][a-zA-Z0-9]{0,3}[a-zA-Z])\/.*/
) )
) { ) {
callsign = item.toUpperCase(); callsign = item.toUpperCase();
@ -559,7 +559,7 @@ function isIOTA(value) {
} }
function isPOTA(value) { function isPOTA(value) {
if (value.match(/^(?!.*FF)[A-Z0-9]{1,3}-\d{4}$/)) { if (value.match(/^(?!.*FF)[A-Z0-9]{1,3}-\d{4,5}$/)) {
return true; return true;
} }
} }