Moved config argument from contructor to method.