Fix StackOverflowError