Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[8.x] Add App::isDebug() method to detect debug mode #39755

Merged
merged 4 commits into from Nov 25, 2021
Merged

[8.x] Add App::isDebug() method to detect debug mode #39755

merged 4 commits into from Nov 25, 2021

Conversation

joelmellon
Copy link
Contributor

Like App::isLocal(), isProduction(), runningInConsole(), isLocale(), etc. it makes sense to have a method on the Container to detect debug mode.

I struggled with the method name, but isDebug() sort of matches most of the methods with similar functionality. I also like:

  • debugMode()
  • debugEnabled()
  • debugModeEnabled()
  • inDebugMode()

Like App::isLocal(), isProduction(), runningInConsole(), isLocale(), etc. it makes sense to have a method on the Container to detect debug mode.

I struggled with the method name, but isDebug() sort of matches most of the methods with similar functionality. I also like:

* debugMode()
* debugEnabled()
* debugModeEnabled()
* inDebugMode()
@GrahamCampbell GrahamCampbell changed the title add App::isDebug() method to detect debug mode [8.x] Add App::isDebug() method to detect debug mode Nov 24, 2021
@taylorotwell taylorotwell merged commit c978893 into laravel:8.x Nov 25, 2021
@williamdes
Copy link
Contributor

Thank you so much !
I needed this right now

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants