$pre =
apply_filters( 'pre_get_site_by_path', null,
$domain,
$path,
$segments,
$paths );
if ( null !==
$pre ) { if ( false !==
$pre && !
$pre instanceof WP_Site
) { $pre =
new WP_Site( $pre );
} return $pre;
} /*
* @todo
* Caching, etc. Consider alternative optimization routes,
* perhaps as an opt-in for plugins, rather than using the pre_* filter.
* For example: The segments filter can expand or ignore paths.
* If persistent caching is enabled, we could query the DB for a path <> '/'
* then cache whether we can just always ignore paths.
*/