]> git.mxchange.org Git - friendica.git/blobdiff - src/Content/OEmbed.php
Merge pull request #12941 from xundeenergie/attend-buttons
[friendica.git] / src / Content / OEmbed.php
index 498a65e33bb79649aa9d46c372277dec5e5507dd..562febdaf916bc0d49a9eebc312a5c0019159be0 100644 (file)
@@ -1,6 +1,6 @@
 <?php
 /**
- * @copyright Copyright (C) 2010-2022, the Friendica project
+ * @copyright Copyright (C) 2010-2023, the Friendica project
  *
  * @license GNU AGPL version 3 or any later version
  *
@@ -316,7 +316,7 @@ class OEmbed
                if ($stopoembed == true) {
                        return preg_replace("/\[embed\](.+?)\[\/embed\]/is", "<!-- oembed $1 --><i>" . DI::l10n()->t('Embedding disabled') . " : $1</i><!-- /oembed $1 -->", $text);
                }
-               return preg_replace_callback("/\[embed\](.+?)\[\/embed\]/is", ['self', 'replaceCallback'], $text);
+               return preg_replace_callback("/\[embed\](.+?)\[\/embed\]/is", [self::class, 'replaceCallback'], $text);
        }
 
        /**
@@ -391,7 +391,7 @@ class OEmbed
         * @param string $title Optional title (default: what comes from OEmbed object)
         * @return string Formatted HTML
         */
-       public static function getHTML(string $url, string $title = '')
+       public static function getHTML(string $url, string $title = ''): string
        {
                $o = self::fetchURL($url, !self::isAllowedURL($url));