Changed to pass configuration as option