fix bug with using incorrect config