|
return res.ResponseFailure.build_system_error( |
I think this could be replaced by:
return res.ResponseFailure.build_system_error(exc) as Response failure can be built from an Exception so you won't repeat the piece of code building a ResponseFailure from an exception in use_case
(i didn't check the git history, but i think this was your intent to separate the buisness logic in use case as much as possible from the «pipe logic» of building a Response from an Exception )
rentomatic/rentomatic/use_cases/room_list_use_case.py
Line 18 in a28222a
I think this could be replaced by:
return res.ResponseFailure.build_system_error(exc)as Response failure can be built from an Exception so you won't repeat the piece of code building a ResponseFailure from an exception in use_case(i didn't check the git history, but i think this was your intent to separate the buisness logic in use case as much as possible from the «pipe logic» of building a Response from an Exception )