Fixed a bug in the adding a point to map method.