diff --git a/src/query/plan/operator.cpp b/src/query/plan/operator.cpp index 0086506ae..9971146de 100644 --- a/src/query/plan/operator.cpp +++ b/src/query/plan/operator.cpp @@ -745,24 +745,6 @@ std::vector ExpandVariable::ModifiedSymbols( namespace { -size_t UnwrapDegreeResult(storage::Result maybe_degree) { - if (maybe_degree.HasError()) { - switch (maybe_degree.GetError()) { - case storage::Error::DELETED_OBJECT: - throw QueryRuntimeException("Trying to get degree of a deleted node."); - case storage::Error::NONEXISTENT_OBJECT: - throw query::QueryRuntimeException( - "Trying to get degree from a node that doesn't exist."); - case storage::Error::SERIALIZATION_ERROR: - case storage::Error::VERTEX_HAS_EDGES: - case storage::Error::PROPERTIES_DISABLED: - throw QueryRuntimeException( - "Unexpected error when getting node degree."); - } - } - return *maybe_degree; -} - /** * Helper function that returns an iterable over * pairs