fixed bug when resolving default geometry.

The mapping to get the index of the geometry field was used twice, resulting in a wrong index and a later ClassCastException when getting the value.
Merge pull request #316 from volaya/defaultGeometry

fixed bug when resolving default geometry.