changed input to factory to String