Added periodical save. And added missing variable to config.xml