Minor code review

This commit is contained in:
Raymond Hill 2024-09-14 09:20:54 -04:00
parent f9ab4b7504
commit 41d49921c8
No known key found for this signature in database
GPG key ID: 25E1490B761470C2

View file

@ -257,7 +257,7 @@ export const FilteringContext = class {
const c0 = ipaddr.charCodeAt(0);
if ( c0 === 0x5B /* [ */ ) {
return (this.ipaddress = ipaddr.slice(1, -1));
} else if ( c0 >= 0x30 && c0 <= 0x39 ) {
} else if ( c0 <= 0x39 && c0 >= 0x30 ) {
if ( reIPv4.test(ipaddr) ) {
return (this.ipaddress = ipaddr);
}