Index: src/wp-includes/theme-compat/embed-content.php
===================================================================
--- src/wp-includes/theme-compat/embed-content.php	(revision 40415)
+++ src/wp-includes/theme-compat/embed-content.php	(working copy)
@@ -22,6 +22,11 @@
 			$thumbnail_id = get_the_ID();
 		}
 
+		/**
+         * Added filter for the $thumbnail_id
+         */
+		$thumbnail_id = apply_filters( 'embed_thumbnail_id', $thumbnail_id );
+
 		if ( $thumbnail_id ) {
 			$aspect_ratio = 1;
 			$measurements = array( 1, 1 );
