Fixed a bug related to config file copying