From 3f864bafc8d30e63a79b74f7d3052802c2cc6cef Mon Sep 17 00:00:00 2001
From: Sami Mazouz <sychocouldy@gmail.com>
Date: Mon, 6 Mar 2023 15:24:03 +0100
Subject: [PATCH] fix(regression): custom less validation check

Signed-off-by: Sami Mazouz <sychocouldy@gmail.com>
---
 framework/core/src/Forum/ValidateCustomLess.php | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/framework/core/src/Forum/ValidateCustomLess.php b/framework/core/src/Forum/ValidateCustomLess.php
index 430d35ae1..808a812f5 100644
--- a/framework/core/src/Forum/ValidateCustomLess.php
+++ b/framework/core/src/Forum/ValidateCustomLess.php
@@ -63,7 +63,7 @@ class ValidateCustomLess
         }
 
         // Restrict what features can be used in custom LESS
-        if (preg_match('/@import|data-uri\s*\(/i', $event->settings['custom_less'])) {
+        if (isset($event->settings['custom_less']) && preg_match('/@import|data-uri\s*\(/i', $event->settings['custom_less'])) {
             $translator = $this->container->make(TranslatorInterface::class);
 
             throw new ValidationException([