recurcive cycle fix