Added version check in
Removed undo crap and added version check