Undo Update: repeat cycle functionality, added comments, updated version

All tasks should now be able to be completely undone, including each
cycle of the repeat stage.

Comments were added for readability and one of the if else blocks were
refactored to match up with the flow of the rest of the code.