|Reported by:||nacin||Owned by:|
default-embeds.php is a file loaded conditionally, which triggers an extra sysopen call. This also goes for default-widgets.php, but that's a much larger file.
On the other hand, if we move the single function, wp_embed_handler_googlevideo(), to wp-includes/media.php, we can improve some performance. I don't think we plan to add too many more default embeds, so this seems pretty safe.
We can still only call wp_embed_register_handler() if the load_default_embeds filter returns true (found in wp_maybe_load_embeds(), attached to plugins_loaded).
Only issue could be someone returning false through the filter then treating it as a pluggable function, stealing its name, but I doubt we'd see that anywhere. At worst, we could add a function_exists() check (still better than what we have) or simply rename the function, as embed handlers are identified by a unique ID, not the function name.