Fix set_config + handle no term