Fix error (recursive method call StackOverflowException)