Skip to content

Conversation

@aurelianzaha
Copy link
Contributor

@aurelianzaha aurelianzaha commented Mar 17, 2023

Implicit conversion fo float to int generates warning in PHP 8.1
e.g.:
Deprecated function: Implicit conversion from float 2.5 to int loses precision in Drupal\graphql\Plugin\GraphQL\DataProducer\EntityDefinition\Fields\Weight->resolve() (line 52 of /var/www/html/backend/web/modules/contrib/graphql/src/Plugin/GraphQL/DataProducer/EntityDefinition/Fields/Weight.php)

@klausi
Copy link
Contributor

klausi commented Mar 20, 2023

This happens because we sometimes use float as weight for custom fields that need to be between 2 other predefined fields. That is only half-supported by Drupal core anyway, so I think we can use this as is without test case.

@klausi klausi merged commit 961eb3a into drupal-graphql:8.x-4.x Mar 20, 2023
klausi pushed a commit to klausi/graphql that referenced this pull request Sep 21, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants