bugfix for profile saving