Fix bug in config export that caused bugs when exporting