Merge pull request #15549 from Chocobo1/api

WebAPI: Use specific number to represent non-existing values
This commit is contained in:
Chocobo1
2021-10-11 12:38:38 +08:00
committed by GitHub
4 changed files with 5 additions and 7 deletions

View File

@@ -51,10 +51,8 @@ namespace
const bool isLeftValid = left.isValid();
const bool isRightValid = right.isValid();
if (isLeftValid && isRightValid)
if (isLeftValid == isRightValid)
return threeWayCompare(left, right);
if (!isLeftValid && !isRightValid)
return 0;
return isLeftValid ? -1 : 1;
}