Skip to content

Add some extra phpcs fixer rules for whitespace#2649

Merged
Crabcyborg merged 1 commit into
masterfrom
add_some_extra_phpcs_fixer_rules_for_whitespace
Dec 12, 2025
Merged

Add some extra phpcs fixer rules for whitespace#2649
Crabcyborg merged 1 commit into
masterfrom
add_some_extra_phpcs_fixer_rules_for_whitespace

Conversation

@Crabcyborg
Copy link
Copy Markdown
Contributor

@Crabcyborg Crabcyborg commented Dec 12, 2025

This helps to prevent extra spaces that shouldn't be there.

These are frequently updated in PRs and I'd rather get rid of them then slowly fix this one at a time. The spaces tend to be distractions when developing.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai Bot commented Dec 12, 2025

Walkthrough

This PR applies PHP code style fixer rules to standardize whitespace formatting across the codebase. Changes include removing trailing whitespace, eliminating whitespace in blank lines, and trimming spaces from PHP opening tags. The configuration file enables two new PhpCsFixer rules to enforce these standards.

Changes

Cohort / File(s) Summary
Code style configuration
.php-cs-fixer.php
Enabled two additional PhpCsFixer rules: no_trailing_whitespace and no_whitespace_in_blank_line to automatically trim trailing whitespace and disallow whitespace on blank lines.
Component style formatting
classes/views/styles/components/FrmSliderStyleComponent.php
Adjusted spacing in the value_label assignment line within the constructor; no functional changes.
Template formatting
classes/views/styles/components/templates/slider.php
Removed trailing spaces from PHP opening tags in the slider template (e.g., <?php <?php).
Controller whitespace adjustments
stripe/controllers/FrmTransLiteActionsController.php
Normalized blank lines in replace_success_message and before_save_settings methods; no behavioral changes.
Test formatting
tests/phpunit/helpers/test_FrmCssScopeHelper.php
Adjusted whitespace formatting throughout test file; all test logic and assertions remain unchanged.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~3 minutes

  • All changes are whitespace and formatting only, applied consistently via PhpCsFixer configuration
  • No logic, control flow, or functional modifications present
  • Verify the two new fixer rules are correctly enabled and don't conflict with existing configuration

Possibly related PRs

  • Prepare for 6.25 #2540: Modifies the same file (stripe/controllers/FrmTransLiteActionsController.php) and updates docblock/versioning in the trigger_payment_status_change method.

Pre-merge checks and finishing touches

❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Description check ❓ Inconclusive The pull request has no author-provided description, making it impossible to assess whether any description was related to the changeset. Add a pull request description explaining the purpose of enabling the new PhpCsFixer rules and the whitespace changes made throughout the codebase.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title accurately describes the main change: enabling additional PhpCsFixer rules for whitespace handling in the codebase.
Docstring Coverage ✅ Passed Docstring coverage is 100.00% which is sufficient. The required threshold is 80.00%.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch add_some_extra_phpcs_fixer_rules_for_whitespace

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@Crabcyborg Crabcyborg merged commit b00a2ec into master Dec 12, 2025
36 checks passed
@Crabcyborg Crabcyborg deleted the add_some_extra_phpcs_fixer_rules_for_whitespace branch December 12, 2025 13:48
@Crabcyborg Crabcyborg modified the milestones: 6.27, 6.26.1 Dec 15, 2025
@coderabbitai coderabbitai Bot mentioned this pull request Dec 22, 2025
stephywells pushed a commit that referenced this pull request Apr 4, 2026
…ules_for_whitespace

Add some extra phpcs fixer rules for whitespace
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant