Refactor undo command to be patch
Rename undoCommand to undoManagerCommands
Tidy up