fix config handling bug