Skip to content

refactor(config): extract ConfigKeysMeta into its own file#1310

Merged
JohnVillalovos merged 1 commit intodevelopfrom
jlvillal/xss_removal
Apr 5, 2026
Merged

refactor(config): extract ConfigKeysMeta into its own file#1310
JohnVillalovos merged 1 commit intodevelopfrom
jlvillal/xss_removal

Conversation

@JohnVillalovos
Copy link
Copy Markdown
Collaborator

Move ConfigKeysMeta class from ConfigKeys.php to a dedicated ConfigKeysMeta.php file. Having multiple classes in one file violates PSR-12 and PHP one-class-per-file conventions.

Also update one test to use declare(strict_types=1);

Move ConfigKeysMeta class from ConfigKeys.php to a dedicated
ConfigKeysMeta.php file. Having multiple classes in one file
violates PSR-12 and PHP one-class-per-file conventions.

Also update one test to use `declare(strict_types=1);`
Copilot AI review requested due to automatic review settings April 5, 2026 03:03
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR refactors the configuration key metadata by moving ConfigKeysMeta out of ConfigKeys.php into its own file, and updates the config namespace loader accordingly. It also aligns one infrastructure test with strict typing.

Changes:

  • Extract ConfigKeysMeta into lib/Config/ConfigKeysMeta.php.
  • Update lib/Config/namespace.php to include the new metadata file.
  • Add declare(strict_types=1); to tests/Infrastructure/Config/DeprecatedConfigKeysTest.php.

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.

File Description
tests/Infrastructure/Config/DeprecatedConfigKeysTest.php Adds declare(strict_types=1); for consistent strict typing in this test.
lib/Config/namespace.php Ensures ConfigKeysMeta is loaded after extraction by requiring the new file.
lib/Config/ConfigKeysMeta.php New dedicated file containing section titles and top-level grouping metadata constants.
lib/Config/ConfigKeys.php Removes the embedded ConfigKeysMeta class definition from this file.

Comment thread lib/Config/ConfigKeys.php
@JohnVillalovos JohnVillalovos merged commit 26c7219 into develop Apr 5, 2026
20 checks passed
@JohnVillalovos JohnVillalovos deleted the jlvillal/xss_removal branch April 5, 2026 03:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants