-
Notifications
You must be signed in to change notification settings - Fork 0
Rename order-processing namespace Be\App\* to Be\Pattern\OrderProcessing\* #17
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -2,10 +2,10 @@ | |
|
|
||
| declare(strict_types=1); | ||
|
|
||
| namespace Be\App\Being\Payment; | ||
| namespace Be\Pattern\OrderProcessing\Being\Payment; | ||
|
|
||
| use Be\App\Moment\Potential\PaymentCapture; | ||
| use Be\App\Reason\PaymentGateway; | ||
| use Be\Pattern\OrderProcessing\Moment\Potential\PaymentCapture; | ||
| use Be\Pattern\OrderProcessing\Reason\PaymentGateway; | ||
| use Ray\Di\Di\Inject; | ||
|
Comment on lines
+8
to
9
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🛠️ Refactor suggestion | 🟠 Major 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Verify concrete-vs-interface usage for PaymentGateway in source.
rg -nP 'use\s+Be\\Pattern\\OrderProcessing\\Reason\\PaymentGateway(;|\s)' demos/order-processing/src
rg -nP '#\[Inject\]\s+PaymentGateway\b' demos/order-processing/src
rg -nP 'bind\(PaymentGatewayInterface::class\)\s*->\s*to\(PaymentGateway::class\)' demos/order-processing/src/Module/AppModule.phpRepository: be-framework/be-patterns Length of output: 483 Depend on Reason services must depend on their interface contract, never the concrete implementation. Ray.Di handles binding the interface to the implementation. Proposed fix-use Be\Pattern\OrderProcessing\Reason\PaymentGateway;
+use Be\Pattern\OrderProcessing\Reason\PaymentGatewayInterface;- #[Inject] PaymentGateway $gateway,
+ #[Inject] PaymentGatewayInterface $gateway,🤖 Prompt for AI Agents
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. @CodeRabbit Out of scope for this PR — this is a pre-existing issue (file unchanged apart from the namespace rename). All six Beings in order-processing inject concrete Reason classes instead of interfaces; worth a follow-up PR to convert them together for consistency.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
🧠 Learnings used |
||
| use Ray\InputQuery\Attribute\Input; | ||
|
|
||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.