W3cubDocs

/WordPress

WP_Block_Bindings_Registry::__wakeup()

Wakeup magic method.

Source

public function __wakeup() {
	if ( ! $this->sources ) {
		return;
	}
	if ( ! is_array( $this->sources ) ) {
		throw new UnexpectedValueException();
	}
	foreach ( $this->sources as $value ) {
		if ( ! $value instanceof WP_Block_Bindings_Source ) {
			throw new UnexpectedValueException();
		}
	}
}

Changelog

Version Description
6.5.0 Introduced.

© 2003–2024 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/classes/wp_block_bindings_registry/__wakeup