Fixed issue when no edges are present.