fix the mapreduce