WC_REST_Authentication::set_error()
Set authentication error.
{} It's a method of the class: WC_REST_Authentication{}
No Hooks.
Return
null
. Nothing.
Usage
// protected - for code of main (parent) or child class $result = $this->set_error( $error );
- $error(WP_Error) (required)
- Authentication error data.
Code of WC_REST_Authentication::set_error() WC REST Authentication::set error WC 6.6.1
protected function set_error( $error ) { // Reset user. $this->user = null; $this->error = $error; }