mirror of https://gitee.com/bigwinds/arangodb
fixed index lookup issues
This commit is contained in:
parent
c34d74933b
commit
f059b0e5f7
|
@ -793,16 +793,17 @@ IndexIterator* EdgeIndex::createIterator(
|
|||
THROW_ARANGO_EXCEPTION(TRI_ERROR_DEBUG);
|
||||
}
|
||||
}
|
||||
|
||||
if (keys.empty()) {
|
||||
// nothing to do
|
||||
return nullptr;
|
||||
}
|
||||
|
||||
|
||||
// _from or _to?
|
||||
bool const isFrom =
|
||||
(strcmp(attrNode->getStringValue(), TRI_VOC_ATTRIBUTE_FROM) == 0);
|
||||
|
||||
|
||||
if (keys.empty()) {
|
||||
// nothing to do. still need to return an empty iterator
|
||||
return new EdgeIndexIterator(isFrom ? _edgesFrom : _edgesTo, keys);
|
||||
}
|
||||
|
||||
TRI_IF_FAILURE("EdgeIndex::noIterator") {
|
||||
THROW_ARANGO_EXCEPTION(TRI_ERROR_DEBUG);
|
||||
}
|
||||
|
|
|
@ -474,8 +474,8 @@ IndexIterator* PrimaryIndex::createIterator(
|
|||
}
|
||||
|
||||
if (keys.empty()) {
|
||||
// nothing to do
|
||||
return nullptr;
|
||||
// nothing to do: still new to return an empty iterator
|
||||
return new PrimaryIndexIterator(this, keys);
|
||||
}
|
||||
|
||||
TRI_IF_FAILURE("PrimaryIndex::noIterator") {
|
||||
|
|
Loading…
Reference in New Issue