Repeat function does not work again