if ($in{username} =~ /^(\[a-zA-Z]{2})/ || ' ') { $dirtype = $1 || 'other'; }