Fix recursion mangement