Skip to content

Commit b9217ae

Browse files
committed
Be consistent with how the type is accessed
1 parent c054ebb commit b9217ae

File tree

1 file changed

+2
-7
lines changed

1 file changed

+2
-7
lines changed

src/ConditionAnalyzer/Analyzer.php

+2-7
Original file line numberDiff line numberDiff line change
@@ -199,16 +199,11 @@ private function getIndex()
199199

200200
private function hasValidQueryOperator($hash, $range = null)
201201
{
202-
$hashCondition = $this->getCondition($hash);
203-
204-
$validQueryOp = ComparisonOperator::isValidQueryDynamoDbOperator($hashCondition['type'] ?? null);
202+
$hashConditionType = $this->getCondition($hash)['type'] ?? null;
203+
$validQueryOp = ComparisonOperator::isValidQueryDynamoDbOperator($hashConditionType);
205204

206205
if ($validQueryOp && $range) {
207206
$rangeConditionType = $this->getCondition($range)['type'] ?? null;
208-
if ($rangeConditionType === null) {
209-
return false;
210-
}
211-
212207
$validQueryOp = ComparisonOperator::isValidQueryDynamoDbOperator(
213208
$rangeConditionType,
214209
true

0 commit comments

Comments
 (0)