Dear guys,
I’m running an console command to do something and have to modify some codes to match the console command’s need. Which we don’t use it normally when running via web browser.
So what is my problem. Well… when I’m running a console command, I have to comment some codes and write another piece of codes in replace. And when I’m going back to run from web browser, I have to do undo it. It’s ok if it’s not much just one or two lines but there are so my places all over the apps. If I forget something, my app will crash.
So instead of doing this. How can we write a code to help this like
If (i'm running console) {
do something..
} else {
do something else..
}
Any idea…?
Thanks in advance.