Skip to content

PHPLIB-1634: Support encoding DateTimeInterface instances in aggregation builder #2314

PHPLIB-1634: Support encoding DateTimeInterface instances in aggregation builder

PHPLIB-1634: Support encoding DateTimeInterface instances in aggregation builder #2314

Triggered via pull request February 26, 2025 08:28
Status Failure
Total duration 2m 6s
Artifacts

static-analysis.yml

on: pull_request
Fit to window
Zoom out
Zoom in

Annotations

4 errors
InvalidReturnType: src/Codec/EncodeIfSupported.php#L41
src/Codec/EncodeIfSupported.php:41:22: InvalidReturnType: The declared return type '(BSONType:MongoDB\Codec\EncodeIfSupported as mixed)|(TGeneratedFromParam0:fn-mongodb\codec\encodeifsupported::encodeifsupported as mixed)' for MongoDB\Codec\EncodeIfSupported::encodeIfSupported is incorrect, got '(TGeneratedFromParam0:fn-mongodb\codec\encodeifsupported::encodeifsupported as mixed)|string' (see https://psalm.dev/011)
InvalidReturnType: src/Codec/EncodeIfSupported.php#L41
src/Codec/EncodeIfSupported.php:41:22: InvalidReturnType: The declared return type '(BSONType:MongoDB\Codec\EncodeIfSupported as mixed)|(TGeneratedFromParam0:fn-mongodb\codec\encodeifsupported::encodeifsupported as mixed)' for MongoDB\Codec\EncodeIfSupported::encodeIfSupported is incorrect, got '(TGeneratedFromParam0:fn-mongodb\codec\encodeifsupported::encodeifsupported as mixed)|list<mixed>' (see https://psalm.dev/011)
MixedArgumentTypeCoercion: src/Codec/EncodeIfSupported.php#L45
src/Codec/EncodeIfSupported.php:45:57: MixedArgumentTypeCoercion: Argument 1 of MongoDB\Builder\Encoder\VariableEncoder::encode expects MongoDB\Builder\Expression\Variable, but parent type TGeneratedFromParam0:fn-mongodb\codec\encodeifsupported::encodeifsupported as mixed provided (see https://psalm.dev/194)
Psalm
Process completed with exit code 2.