Fixed a bug where incorrect invocation cause infinite recursion