mirror of
https://github.com/phpbb/phpbb.git
synced 2025-06-28 06:08:52 +00:00
[ticket/13306] move error_reporting call
https://tracker.phpbb.com/browse/PHPBB3-13306 PHPBB3-13306
This commit is contained in:
parent
834a93f76c
commit
0a4ffb7cf8
1 changed files with 3 additions and 2 deletions
|
@ -26,17 +26,18 @@ class error_collector
|
|||
* the error_reporting() function will be used to determine which errors
|
||||
* the collector will keep.
|
||||
*
|
||||
* @see PHPBB3-13306
|
||||
* @param int|null $error_types
|
||||
*/
|
||||
function __construct($error_types = null)
|
||||
{
|
||||
$this->errors = array();
|
||||
$this->error_types = ($error_types !== null) ? $error_types : error_reporting();
|
||||
$this->error_types = $error_types;
|
||||
}
|
||||
|
||||
function install()
|
||||
{
|
||||
set_error_handler(array(&$this, 'error_handler'), $this->error_types);
|
||||
set_error_handler(array(&$this, 'error_handler'), ($this->error_types !== null) ? $this->error_types : error_reporting());
|
||||
}
|
||||
|
||||
function uninstall()
|
||||
|
|
Loading…
Add table
Reference in a new issue