Bug fix in loading config file