Remove recursion