As I explained in article, we are going to see SOLID principle in context of Laravel. So I gave example from Laravel and how to achive "every entity should have single responsibility".
As controller store method meant to store data not validation of data.
So we extract validation logic to seprate class called Request and in this way we implemented single responsibility principle.
Although there a tons of examples with general purpose code and with Laravel. But with laravel it is simple and easy to understand example.
As I explained in article, we are going to see SOLID principle in context of Laravel. So I gave example from Laravel and how to achive "every entity should have single responsibility".
As controller store method meant to store data not validation of data.
So we extract validation logic to seprate class called Request and in this way we implemented single responsibility principle.
Although there a tons of examples with general purpose code and with Laravel. But with laravel it is simple and easy to understand example.
now as you mentioned in comment "As controller store method meant to store data not validation of data.
So we extract validation logic to seprate class called Request and in this way we implemented single responsibility principle."
now its clear..
Best of luck