fixed namespace check problem