small refactoring of the version module