correcting param in toMoment