Fixed replace word bug.