We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 3f95c6b commit ee53d93Copy full SHA for ee53d93
include/CXXGraph/Graph/Graph_impl.hpp
@@ -545,8 +545,7 @@ shared<DegreeMatrix<T>> Graph<T>::getDegreeMatrix() const {
545
const std::vector<std::pair<shared<const Node<T>>, shared<const Edge<T>>>>
546
&neighbors = nodePair.second;
547
548
- const int degree = neighbors.size();
549
- (*degreeMatrix)[node] = degree;
+ (*degreeMatrix)[node] = neighbors.size();
550
}
551
552
return degreeMatrix;
0 commit comments