WP_Error::remove( string|int $code )

Removes the specified error.


Description

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


Parameters

$code

(string|int) (Required) Error code.


Source

File: wp-includes/class-wp-error.php

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

Changelog

Changelog
Version Description
WP-4.1.0 Introduced.