Fix error with large nesting