do not do _saveConfig() twice on modified modules

and do not mark wrongly as restarted too early