-
Notifications
You must be signed in to change notification settings - Fork 533
Open
Labels
enhancementNew feature or requestNew feature or request
Description
Summary
Opportunity validation currently uses addError directly inside the validation
service, which mixes validation logic with user-facing error handling.
Suggested Solution
Refactor Opportunity validation to throw custom exception classes
(e.g., OpportunityValidationException) from the validation service.
Catch these exceptions in the OpportunityTriggerHandler and surface
user-friendly messages using addError, improving separation of concerns
and aligning with the handler/service pattern used in this repository.
Alternative Solutions
Continue using addError directly in the validation service, but this would
keep business validation logic tightly coupled with UI error handling.
Code of Conduct
- I agree to follow this project's Code of Conduct
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
enhancementNew feature or requestNew feature or request