Changed 'sort()' to accept an optional Boolean, which will return the Nodes