Opened 3 years ago
Last modified 3 years ago
#41902 accepted enhancement
wp-load.php: comment for error reporting levels
Reported by: |
|
Owned by: |
|
---|---|---|---|
Milestone: | Awaiting Review | Priority: | normal |
Severity: | trivial | Version: | 0.71 |
Component: | Bootstrap/Load | Keywords: | has-patch commit |
Focuses: | docs | Cc: |
Description (last modified by )
Yes, looks good to me.
I think this can just be committed, not much to break here.
Attachments (2)
Change History (7)
#3
in reply to:
↑ 2
@
3 years ago
@schlessera
Thanks for suggesting!
Nice one isn't it!?
I agree to add your comment, this time!
This ticket was my first one at WordCamp Tokyo. So I'm not sure this was the good ticket.
I'm so happy to get any feedback!
Replying to schlessera:
Thanks for the ticket and patch, @sasagar !
If we go ahead and add an additional comment, we should also make sure it provides added value as well.
How about something like this:
/* * Initialize error reporting to a known set of levels. * * This will be adapted in wp-includes/load.php based on the WP_DEBUG setting. * @see http://php.net/manual/en/errorfunc.constants.php List of known error levels. */ error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR );
Note: See
TracTickets for help on using
tickets.
Thanks for the ticket and patch, @sasagar !
If we go ahead and add an additional comment, we should also make sure it provides added value as well.
How about something like this:
/* * Initialize error reporting to a known set of levels. * * This will be adapted in wp-includes/load.php based on the WP_DEBUG setting. * @see http://php.net/manual/en/errorfunc.constants.php List of known error levels. */ error_reporting( E_CORE_ERROR | E_CORE_WARNING | E_COMPILE_ERROR | E_ERROR | E_WARNING | E_PARSE | E_USER_ERROR | E_USER_WARNING | E_RECOVERABLE_ERROR );