Skip to content

Commit

Permalink
Merge pull request #168 from JeroenJRP/parse-tags-fix
Browse files Browse the repository at this point in the history
Forgot to pass the variables to the anonymous function
  • Loading branch information
reganlawton authored Dec 10, 2024
2 parents f98a284 + 47bef00 commit 922e6f8
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/services/OembedService.php
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ public function parseTags(string $input, array $options = [], array $cacheProps
return '';
}

$output = preg_replace_callback('/\<oembed\s(?:.*?)url="(.*?)"(?:.*?)>(?:.*?)<\/oembed>/i', function($matches) {
$output = preg_replace_callback('/\<oembed\s(?:.*?)url="(.*?)"(?:.*?)>(?:.*?)<\/oembed>/i', function($matches) use ($options, $cacheProps) {
$url = $matches[1];
return $this->render($url, $options, $cacheProps);
}, $input);
Expand Down

0 comments on commit 922e6f8

Please sign in to comment.