@@ -90,7 +90,6 @@ public function create(string $className, string $typeName): Type
9090 foreach ($ customOperators as $ customOperator ) {
9191 /** @var LeafType $leafType */
9292 $ leafType = $ this ->types ->get ($ customOperator ->type );
93- /** @var class-string $operator */
9493 $ operator = $ customOperator ->operator ;
9594 $ operators [$ operator ] = $ leafType ;
9695 }
@@ -176,7 +175,7 @@ private function readCustomOperatorsFromAttribute(ReflectionClass $class): void
176175 /**
177176 * Get configuration for field.
178177 *
179- * @param array<class-string, LeafType> $operators
178+ * @param array<class-string<AbstractOperator> , LeafType> $operators
180179 */
181180 private function getFieldConfiguration (string $ typeName , string $ fieldName , array $ operators ): array
182181 {
@@ -189,7 +188,7 @@ private function getFieldConfiguration(string $typeName, string $fieldName, arra
189188 /**
190189 * Return a map of operator class name and their leaf type, including custom operator for the given fieldName.
191190 *
192- * @return array<class-string, LeafType> indexed by operator class name
191+ * @return array<class-string<AbstractOperator> , LeafType> indexed by operator class name
193192 */
194193 private function getOperators (string $ fieldName , LeafType $ leafType , bool $ isAssociation , bool $ isCollection ): array
195194 {
@@ -231,7 +230,6 @@ private function getOperators(string $fieldName, LeafType $leafType, bool $isAss
231230 foreach ($ this ->customOperators [$ fieldName ] as $ filter ) {
232231 /** @var LeafType $leafType */
233232 $ leafType = $ this ->types ->get ($ filter ->type );
234- /** @var class-string $operator */
235233 $ operator = $ filter ->operator ;
236234 $ operators [$ operator ] = $ leafType ;
237235 }
@@ -245,7 +243,7 @@ private function getOperators(string $fieldName, LeafType $leafType, bool $isAss
245243 /**
246244 * Get the type for a specific field.
247245 *
248- * @param array<class-string, LeafType> $operators
246+ * @param array<class-string<AbstractOperator> , LeafType> $operators
249247 */
250248 private function getFieldType (string $ typeName , string $ fieldName , array $ operators ): InputObjectType
251249 {
@@ -263,7 +261,7 @@ private function getFieldType(string $typeName, string $fieldName, array $operat
263261 /**
264262 * Get operators configuration for a specific leaf type.
265263 *
266- * @param array<class-string, LeafType> $operators
264+ * @param array<class-string<AbstractOperator> , LeafType> $operators
267265 */
268266 private function getOperatorConfiguration (array $ operators ): array
269267 {
0 commit comments