fixing bug for adding vertex to vertex set