From 880ffeedf728e0318063e691f481998cfa5bdc58 Mon Sep 17 00:00:00 2001 From: Guy Sartorelli Date: Tue, 12 Nov 2024 11:23:33 +1300 Subject: [PATCH] API Use new class_description configuration --- lang/en.yml | 1 + src/ErrorPage.php | 5 +++++ 2 files changed, 6 insertions(+) diff --git a/lang/en.yml b/lang/en.yml index 4532366..650ad90 100644 --- a/lang/en.yml +++ b/lang/en.yml @@ -1,5 +1,6 @@ en: SilverStripe\ErrorPage\ErrorPage: + CLASS_DESCRIPTION: 'Custom content for different error cases (e.g. "Page not found")' CODE: 'Error code' CODE_400: '400 - Bad Request' CODE_401: '401 - Unauthorized' diff --git a/src/ErrorPage.php b/src/ErrorPage.php index e35efb6..53f04cf 100644 --- a/src/ErrorPage.php +++ b/src/ErrorPage.php @@ -52,8 +52,13 @@ class ErrorPage extends Page private static $allowed_children = []; + /** + * @deprecated 5.4.0 use class_description instead. + */ private static $description = 'Custom content for different error cases (e.g. "Page not found")'; + private static $class_description = 'Custom content for different error cases (e.g. "Page not found")'; + private static $icon_class = 'font-icon-p-error'; /**