Fix maxspeed unit detection

Centroid calculations were failing for two node ways.
It just uses the middle node now.