some fixes, added invokerepeat