WordPress at a glance
function is not described


Manifest_Reader::read_manifests() public WC 1.0

Reads all of the manifests in the given plugin paths.

{} It's a method of the class: Manifest_Reader{}

No Hooks.


Array. $path_map The path map we've built using the manifests in each plugin.


$Manifest_Reader = new Manifest_Reader();
$Manifest_Reader->read_manifests( $plugin_paths, $manifest_path, $path_map );
$plugin_paths(array) (required) (passed by reference — &)
The paths to the plugins we're loading the manifest in.
$manifest_path(string) (required) (passed by reference — &)
The path that we're loading the manifest from in each plugin.
$path_map(array) (required) (passed by reference — &)
The path map to add the contents of the manifests to.

Code of Manifest_Reader::read_manifests() WC 5.2.2

public function read_manifests( $plugin_paths, $manifest_path, &$path_map ) {
	$file_paths = array_map(
		function ( $path ) use ( $manifest_path ) {
			return trailingslashit( $path ) . $manifest_path;

	foreach ( $file_paths as $path ) {
		$this->register_manifest( $path, $path_map );

	return $path_map;