change the way of version detect for undo persistence
Merge pull request #41 from ruanyl/master

change the way of version detect for undo persistence