From 800ebd6373191d1d857975f7df9920dde8b3f9c7 Mon Sep 17 00:00:00 2001 From: Andrew Dolgov Date: Fri, 18 Jun 2021 11:52:06 +0300 Subject: [PATCH] revise previous a little bit more --- classes/urlhelper.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/classes/urlhelper.php b/classes/urlhelper.php index d5fa51dbc..b2c1331b6 100644 --- a/classes/urlhelper.php +++ b/classes/urlhelper.php @@ -52,7 +52,7 @@ class UrlHelper { $owner_attribute == "href") { return $rel_url; // allow limited subset of inline base64-encoded images for IMG elements - } else if ($rel_parts["scheme"] == "data" && + } else if ($rel_parts["scheme"] ?? "" == "data" && preg_match('%^image/(webp|gif|jpg|png|svg);base64,%', $rel_parts["path"]) && $owner_element == "img" && $owner_attribute == "src") {