Skip to content

[LINTFIX] Lint fixes for includes/Products/Sync.php#3081

Closed
sol-loup wants to merge 1 commit intomainfrom
sollipse-lintfixes-4-23-A
Closed

[LINTFIX] Lint fixes for includes/Products/Sync.php#3081
sol-loup wants to merge 1 commit intomainfrom
sollipse-lintfixes-4-23-A

Conversation

@sol-loup
Copy link
Copy Markdown
Contributor

@sol-loup sol-loup commented Apr 23, 2025

Description

This pull request fixes all PHPCS / linting issues in includes/Products/Sync.php without altering runtime behaviour.

Key fixes:

  1. Replaced the prohibited or logical operator with ||.
  2. Corrected docblock parameter names and added explicit types / return descriptions.
  3. Removed superfluous blank line before the class closing brace.

These updates bring the file into full compliance with the project’s coding‑standards, improving readability and maintainability while keeping functionality intact.

Type of change

  • Syntax change (non‑breaking change which fixes code modularity, linting or phpcs issues)

Checklist

  • I have commented my code, particularly in hard‑to‑understand areas.
  • I have confirmed that my changes do not introduce any new PHPCS warnings or errors.
  • I have checked plugin debug logs that my changes do not introduce any new PHP warnings or FATAL errors.
  • I followed general Pull Request best practices.
  • I have added tests (if necessary) and all the new and existing unit tests pass locally with my changes.
  • I have completed dogfooding and QA testing, or I have conducted thorough due diligence to ensure that it does not break existing functionality.
  • I have updated or requested update to plugin documentation (if necessary).

Changelog entry

Fix – Resolve PHPCS / linting issues in the product sync handler (includes/Products/Sync.php).

Test Plan

  1. Run composer phpcs and verify zero errors / warnings.
  2. Activate the plugin in a test WooCommerce site and confirm:
    • Product sync actions still trigger as expected (create, update, delete requests).
    • No new PHP warnings or fatal errors appear in logs.
  3. Manually trigger stock updates and verify they are queued for sync correctly.

Screenshots

N/A

@facebook-github-bot
Copy link
Copy Markdown
Contributor

@sol-loup has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@sol-loup sol-loup changed the title sollipse lintfixes 4 23 A Lint fixes for includes/Products/Sync.php Apr 23, 2025
@facebook-github-bot
Copy link
Copy Markdown
Contributor

@sol-loup has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator.

@sol-loup sol-loup changed the title Lint fixes for includes/Products/Sync.php [LINTFIX] Lint fixes for includes/Products/Sync.php Apr 23, 2025
@facebook-github-bot
Copy link
Copy Markdown
Contributor

@sol-loup merged this pull request in 4299971.

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.

2 participants