wphooks.info - deprecated_constructor_trigger_error

deprecated_constructor_trigger_error

(trunk - 5.1-alpha-44286)

The hook occurs in the following file:

wp-includes/functions.php:
4148
4149
4150
4151
4152
4153
4154
4155
4156
4157
4158
4159
4160
4161
4162
4163
4164
4165
4166
	/**
	 * Filters whether to trigger an error for deprecated functions.
	 *
	 * `WP_DEBUG` must be true in addition to the filter evaluating to true.
	 *
	 * @since 4.3.0
	 *
	 * @param bool $trigger Whether to trigger the error for deprecated functions. Default true.
	 */
	if ( WP_DEBUG && apply_filters( 'deprecated_constructor_trigger_error', true ) ) {
		if ( function_exists( '__' ) ) {
			if ( ! empty( $parent_class ) ) {
				/* translators: 1: PHP class name, 2: PHP parent class name, 3: version number, 4: __construct() method */
				trigger_error(
					sprintf(
						__( 'The called constructor method for %1$s in %2$s is <strong>deprecated</strong> since version %3$s! Use %4$s instead.' ),
						$class,
						$parent_class,
						$version,