Fix repeat loop.