Problem/Motivation

I begin to upgrade a site from Drupal 10 to Drupal 11 The site still is in Drupal 10, and one of the module I need to update was Video Embed Facebook. and when I update de module I get this error:

Fatal error: Declaration of Drupal\video_embed_facebook\Plugin\video_embed_field\Provider\Facebook::renderEmbedCode($width, $height, $autoplay) must be compatible with Drupal\video_embed_field\ProviderPluginBase::renderEmbedCode($width, $height, $autoplay, $title_format = null, $use_title_fallback = true) in /var/www/html/web/modules/contrib/video_embed_facebook/src/Plugin/video_embed_field/Provider/Facebook.php on line 18

the eror appear in the node where is a facebook video. The Second problem I get is in frontpage all the html desapear if I try to put that node in frontpage like content.

CommentFileSizeAuthor
#3 3589818.patch716 bytesshank115
Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

koffer created an issue. See original summary.

koffer’s picture

Posdata
I thought the page, in that node, had a Facebook video, but no, it was a YouTube video. So it doesn't matter if it has a Facebook video or not; with the module installed, it throws the error.

shank115’s picture

Status: Active » Needs review
StatusFileSize
new716 bytes

Try this patch

guillaumeg made their first commit to this issue’s fork.

guillaumeg’s picture

Hi,

I can confirm we need to update the signature of the renderEmbedCode method in Facebook.php to stay compatible with video_embed_field 3.1.

I've created a mergerequest, but we might also want to create a new 3.x tag for video_embed_facebook to align with video_embed_field versioning.

guillaumeg’s picture

Priority: Normal » Critical
Status: Needs review » Reviewed & tested by the community