Added a new option here to accept the filename parameter.