Skip to content

HQD-69: fix Customer for 8.4#115

Open
bladeroot wants to merge 1 commit intohiqdev:masterfrom
bladeroot:HQD-69
Open

HQD-69: fix Customer for 8.4#115
bladeroot wants to merge 1 commit intohiqdev:masterfrom
bladeroot:HQD-69

Conversation

@bladeroot
Copy link
Copy Markdown
Member

@bladeroot bladeroot commented Mar 31, 2026

Summary by CodeRabbit

  • Refactor
    • Improved type safety in customer management code.

@coderabbitai
Copy link
Copy Markdown
Contributor

coderabbitai bot commented Mar 31, 2026

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 28a74cd9-47ef-4d3f-bad8-256b3c2c9882

📥 Commits

Reviewing files that changed from the base of the PR and between 53a3976 and 59952b0.

📒 Files selected for processing (1)
  • src/customer/Customer.php

📝 Walkthrough

Walkthrough

Updated the Customer class constructor to use PHP's nullable type syntax for the $seller parameter, changing from CustomerInterface $seller = null to ?CustomerInterface $seller = null. This makes the type hint explicitly nullable while preserving the default value.

Changes

Cohort / File(s) Summary
Parameter Type Hint Update
src/customer/Customer.php
Updated Customer::__construct() third parameter $seller to use nullable type declaration (?CustomerInterface), making the type system more explicit while maintaining backward compatibility.

Estimated code review effort

🎯 1 (Trivial) | ⏱️ ~2 minutes

Poem

🐰 A hop, a skip, a type so right,
The nullable seller shines so bright,
With question marks in PHP's way,
The code grows clearer every day!

🚥 Pre-merge checks | ✅ 2 | ❌ 1

❌ Failed checks (1 inconclusive)

Check name Status Explanation Resolution
Title check ❓ Inconclusive The title references a specific issue (HQD-69) and version (8.4) but lacks clarity about the actual change: updating a type hint to use PHP's nullable type syntax. Consider a more descriptive title like 'Use nullable type hint for Customer seller parameter' to better convey the technical change being made.
✅ Passed checks (2 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests

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.

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.

1 participant