config now returns promise