Hi, I just wonder if laravel doesn't have a built-in function to check how debug mode is set. The point is that I need to have some functions in the project commonly accessible. But for production I want them to be subject to some protection. So I just blew up the condition
If you execute the config:cache command during your deployment process, you should be sure that you are only calling the env function from within your configuration files. Once the configuration has been cached, the .env file will not be loaded and all calls to the env function will return null.