How can I get the vertices of an EdgesGeometry?

I am trying to acquire the vertices present in the custom created edges geometry using the following lines of code:

var edges = new THREE.EdgesGeometry(geometry);
var edgeMaterial = new THREE.LineBasicMaterial({ color: 0x0000ff, linewidth: 5 });
var wireframe = new THREE.LineSegments(edges, edgeMaterial);

However, the console shows ‘undefined’ even though I have ‘edges’ as non null. Is it not possible to print the vertices just like geometry.vertices ?

Nevermind, after some searching, I got the solution here thanks to @Mugen87.