calling an external api on a middleware is not a good idea. You should consider caching that api data or maybe maintain a database for that (this is insane though :D )
also if you can move the language selection and set logic to separate function it should be okay.
astroanu said:
calling an external api on a middleware is not a good idea. You should consider caching that api data or maybe maintain a database for that (this is insane though :D )
also if you can move the language selection and set logic to separate function it should be okay.
Do you mean like storing the http://www.wipmania.com/ information in the session? My biggest problem however, is still how do handle the redirects correctly. I am not sure how to structure this. Could I create a middleware if I move the external api data into a session? I have never created any middleware before
Sign in to participate in this thread!
The Laravel portal for problem solving, knowledge sharing and community building.
The community