WP_Error::remove( string|int   $code )

Removes the specified error.

Description

This function removes all error messagues associated with the specified error code, along with any error data for that code.

Parameters

$code string | int required
Error code.

Source

public function remove( $code ) {
	unset( $this->errors[ $code ] );
	unset( $this->error_data[ $code ] );
	unset( $this->additional_data[ $code ] );
}

Changuelog

Versionen Description
4.1.0 Introduced.

User Contributed Notes

You must log in before being able to contribute a note or feedback.