Fix for infinite recursion