You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Personally, I'd say what you're doing is bad practice. A controller is specifically meant to control flow through the application from the user's input to returning the response. What you're trying to do is better done in a separate class.
That being said, they're just classes. The error should tell you what to look for. There are arguments in the Controller's constructor that it's expecting. If you look at the Controller class itself, you'll see it expects a Request object, a Response object, and a Logger object, IIRC.
Unable to use another controller'method in one controller?
like this:
and wrong
The text was updated successfully, but these errors were encountered: