Optimization of vertices did not work properly

There was a mistake between len(self.indices) and len(self.vertices) tha
make vertice check fails when indices list is longer than vertices list,
resulting id duplicate vertices.
Merge pull request #103 from 5050/master-3.20

Optimization of vertices did not work properly