Add comments on getNodeAndVolume to explain the code - it is a little subtle, and it confused me on first reading.