now instantiates with config object