Code Duplication    Length = 3-3 lines in 2 locations

modules/graphql_core/src/Plugin/GraphQL/Fields/EntityQuery/EntityQuery.php 2 locations

@@ 302-304 (lines=3) @@
299
      }
300
      // Unary operators need a single value.
301
      else if (!empty($operator) && $this->isUnaryOperator($operator)) {
302
        if (empty($value) || count($value) > 1) {
303
          throw new ResolveException(sprintf("Unary operators must be associated with a single value (field '%s').", $field));
304
        }
305
306
        // Pick the first item from the values.
307
        $value = reset($value);
@@ 311-313 (lines=3) @@
308
      }
309
      // Range operators need exactly two values.
310
      else if (!empty($operator) && $this->isRangeOperator($operator)) {
311
        if (empty($value) || count($value) !== 2) {
312
          throw new ResolveException(sprintf("Range operators must require exactly two values (field '%s').", $field));
313
        }
314
      }
315
      // Null operators can't have a value set.
316
      else if (!empty($operator) && $this->isNullOperator($operator)) {