Automattic\WooCommerce\Admin\Notes

Note::apply_changes()publicWC 3.0.0

Merge changes with data and clear.

Method of the class: Note{}

No Hooks.

Return

null. Nothing (null).

Usage

$Note = new Note();
$Note->apply_changes();

Changelog

Since 3.0.0 Introduced.

Note::apply_changes() code WC 8.6.1

public function apply_changes() {
	$this->data = array_replace_recursive( $this->data, $this->changes ); // @codingStandardsIgnoreLine

	// Note actions need to be replaced wholesale.
	// Merging arrays doesn't allow for deleting note actions.
	if ( isset( $this->changes['actions'] ) ) {
		$this->data['actions'] = $this->changes['actions'];
	}

	$this->changes = array();
}