More refactoring, a fix to my InspIRCd::IsValidMask