refactor restoreAndPlug
Merge branch 'master' of https://github.com/genericsystem/genericsystem2011.git