fix bug in the config generation