bugfix: use equals to compare vertexes instead of ==