{"type":"rich","version":"1.0","provider_name":"Transistor","provider_url":"https://transistor.fm","author_name":"Programming Tech Brief By HackerNoon","title":"Refactoring Ruby Code: From Service Objects to Object Design","html":"<iframe width=\"100%\" height=\"180\" frameborder=\"no\" scrolling=\"no\" seamless src=\"https://share.transistor.fm/e/d95a1486\"></iframe>","width":"100%","height":180,"duration":341,"description":"\n        This story was originally published on HackerNoon at: https://hackernoon.com/refactoring-ruby-code-from-service-objects-to-object-design.\nAs technology evolves and our understanding of scalable and maintainable code deepens, optimizing software architecture becomes paramount. In the realm of Ruby\nCheck more stories related to programming at: https://hackernoon.com/c/programming.\n            You can also check exclusive content about #ruby-programming, #software-architecture, #code-refactoring, #law-of-demeter, #software-design-patterns, #service-objects-in-ruby, #codebase-optimization, #object-design-in-ruby,  and more.\nThis story was written by: @aleksandrov. Learn more about this writer by checking @aleksandrov's about page,\n            and for more stories, please visit hackernoon.com.\nService objects were discussed many times by several authors. Usually, they are a code smell, and I will not try to explain why again. I will show a practical example of refactoring a service object into an object-orientated code.\n\nI will not try to blame anybody; probably, it was me who clicked the “Approve” button on the PR that introduced the code listed below. Anyway, I believe it is always better to return and work on your mistakes.","thumbnail_url":"https://img.transistorcdn.com/KhCapPSRkLGL2Xw8888yuChkNRWthaKapLYTvNdu4W4/rs:fill:0:0:1/w:400/h:400/q:60/mb:500000/aHR0cHM6Ly9pbWct/dXBsb2FkLXByb2R1/Y3Rpb24udHJhbnNp/c3Rvci5mbS9zaG93/LzQxMTY2LzE2ODM1/ODIzMzAtYXJ0d29y/ay5qcGc.webp","thumbnail_width":300,"thumbnail_height":300}