collider vertices too close?

unity tells me: The collider did not create a collision shape as it failed verification. This could be because it was deemed too small or its vertices were too close. Vertices can also become close under certain rotations.

is there way how to disable polygoncollider2d to not accept all vertices?

//make a new array for your vertices
Vector2 points = new Vector2[10];

//set them
points[0] = …
points[1] = …
points[2] = …
points[3] = …
points[4] = …
points[5] = …
points[6] = …
etc…

gameObject.getComponent().points = points