fix invalid namespace

Fix Namespace Error when InvalidArgumentException is thrown.