replace may receive filename as