Clean code

This commit is contained in:
julien
2026-03-27 22:30:10 +01:00
parent 68c547ddcb
commit 7757628a94
29 changed files with 164 additions and 268 deletions

View File

@@ -2,7 +2,7 @@
declare(strict_types=1);
class MarkdownService
class MarkdownService extends Prefab
{
private const ALLOWED_TAGS = [
'p', 'h1', 'h2', 'h3', 'h4', 'h5', 'h6',
@@ -10,7 +10,7 @@ class MarkdownService
'strong', 'em', 'a', 'img', 'hr', 'br',
];
public static function compile(string $markdown, Media $media): string
public function compile(string $markdown, Media $media): string
{
$markdown = trim($markdown);
if ($markdown === '') {