From 6b9a979c3543c52dc8cc7e4c8150daf31acdc6be Mon Sep 17 00:00:00 2001 From: Tim Kleyersburg Date: Sat, 2 Nov 2024 08:41:57 +0100 Subject: [PATCH] fix: allow images to start with http/https --- src/Extensions/MarkdownImageExtension.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Extensions/MarkdownImageExtension.php b/src/Extensions/MarkdownImageExtension.php index d48889f..7bc1a08 100644 --- a/src/Extensions/MarkdownImageExtension.php +++ b/src/Extensions/MarkdownImageExtension.php @@ -28,7 +28,7 @@ public function onDocumentParsed(DocumentParsedEvent $event): void } // if this isn't an external image, set the prefix - if (! Str::startsWith($node->getUrl(), 'http')) { + if (! Str::startsWith($node->getUrl(), ['http://', 'https://'])) { $originalUrl = $node->getUrl(); $node->setUrl(route('prezet.image', $originalUrl, false));