Clear and concise description of the problem
Arguably, toResponse mapping should be a controller-level concern, and the service layer should not be aware of it.
Suggested solution
Move all toResponse invocations to the controller layer.
Alternative
Leave the toResponse invocations where they are in the service layer, if we determine that the service layer should have knowledge of the desired API-level format.
Additional context
Consider our "project structure" and "architecture" docs.
Validations
Clear and concise description of the problem
Arguably,
toResponsemapping should be a controller-level concern, and the service layer should not be aware of it.Suggested solution
Move all
toResponseinvocations to the controller layer.Alternative
Leave the
toResponseinvocations where they are in the service layer, if we determine that the service layer should have knowledge of the desired API-level format.Additional context
Consider our "project structure" and "architecture" docs.
Validations
README.md.