Skip to content
Prev Previous commit
Next Next commit
Avoid creating a tuple
  • Loading branch information
vlyubin committed Apr 10, 2015
commit 11a20ec2285342247c0675411f0ebf4aadc6eb51
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@ object CatalystTypeConverters {
val convertedMap: HashMap[Any, Any] = HashMap()
while (iter.hasNext) {
val entry = iter.next()
convertedMap += Tuple2(keyConverter(entry.getKey), valueConverter(entry.getValue))
convertedMap(keyConverter(entry.getKey)) = valueConverter(entry.getValue)
}
convertedMap

Expand Down