Skip to content

Commit

Permalink
PR changes
Browse files Browse the repository at this point in the history
  • Loading branch information
mpintaric55334 committed Oct 22, 2023
1 parent 79f49db commit 07b3e03
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions cpp/algo_module/algorithm/algo.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@ void Algo::Cover(mgp_list *args, mgp_graph *memgraph_graph, mgp_result *result,
try {
auto list_nodes = arguments[0].ValueList();
std::unordered_set<mgp::Node> nodes;
for (const auto elem : list_nodes) {
for (const auto &elem : list_nodes) {
auto node = elem.ValueNode();
nodes.insert(node);
}

for (auto node : nodes) {
for (auto rel : node.OutRelationships()) {
for (const auto &node : nodes) {
for (const auto rel : node.OutRelationships()) {
if (nodes.find(rel.To()) != nodes.end()) {
auto record = record_factory.NewRecord();
record.Insert(std::string(kCoverRet1).c_str(), rel);
Expand Down

0 comments on commit 07b3e03

Please sign in to comment.