added safeguard for namespace in release mode