Skip to content

Conversation

@froozeify
Copy link
Member

Checklist before requesting a review

  • I have read the CONTRIBUTING document.
  • I have performed a self-review of my code.
  • I have added tests that prove my fix is effective or that my feature works.
  • This change requires a documentation update.

Description

PHP 8.5 trigger warnings when a null array key is set

https://github.com/glpi-project/glpi/actions/runs/19026238231/job/54330365672?pr=21741

@trasher
Copy link
Contributor

trasher commented Nov 3, 2025

Issue is spotted from this PR: #21741 on v11

@froozeify froozeify force-pushed the 10.0/fix-null-array-keys branch from 7c7a65a to 36a6fc8 Compare November 3, 2025 15:23
@froozeify froozeify marked this pull request as ready for review November 3, 2025 15:23
Copy link
Contributor

@AdrienClairembault AdrienClairembault left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Maybe you'll also need to migrate existing values from the database?

@froozeify
Copy link
Member Author

The empty check support null value as an empty string so I don't think the migration from the database is required.

More so, the current null value are stored in the db as empty string, the encoding is done via PlanningEvent::encodeRrule

@cedric-anne cedric-anne merged commit b90518a into glpi-project:10.0/bugfixes Nov 4, 2025
8 checks passed
@cedric-anne cedric-anne added this to the 10.0.21 milestone Nov 4, 2025
@cedric-anne cedric-anne added the bug label Nov 4, 2025
@froozeify froozeify deleted the 10.0/fix-null-array-keys branch November 4, 2025 09:01
@froozeify froozeify mentioned this pull request Nov 10, 2025
2 tasks
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.

4 participants