fix 2 bugs with exclude handling