From 0da034c45548091ce759a67200581953834e58e5 Mon Sep 17 00:00:00 2001 From: Guy Sartorelli <36352093+GuySartorelli@users.noreply.github.com> Date: Thu, 19 Sep 2024 13:45:08 +1200 Subject: [PATCH 1/2] ENH Don't use deprecated method (#786) --- src/Model/BlogPostFeaturedExtension.php | 2 +- src/Widgets/BlogArchiveWidget.php | 2 +- src/Widgets/BlogArchiveWidgetController.php | 2 +- src/Widgets/BlogCategoriesWidget.php | 2 +- src/Widgets/BlogCategoriesWidgetController.php | 2 +- src/Widgets/BlogFeaturedPostsWidget.php | 2 +- src/Widgets/BlogRecentPostsWidget.php | 2 +- src/Widgets/BlogRecentPostsWidgetController.php | 2 +- src/Widgets/BlogTagsCloudWidget.php | 2 +- src/Widgets/BlogTagsCloudWidgetController.php | 2 +- src/Widgets/BlogTagsWidget.php | 2 +- src/Widgets/BlogTagsWidgetController.php | 2 +- 12 files changed, 12 insertions(+), 12 deletions(-) diff --git a/src/Model/BlogPostFeaturedExtension.php b/src/Model/BlogPostFeaturedExtension.php index 9d7ba44..fb2bf93 100644 --- a/src/Model/BlogPostFeaturedExtension.php +++ b/src/Model/BlogPostFeaturedExtension.php @@ -17,7 +17,7 @@ class BlogPostFeaturedExtension extends DataExtension { public function __construct() { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogArchiveWidget.php b/src/Widgets/BlogArchiveWidget.php index f46a814..916154d 100644 --- a/src/Widgets/BlogArchiveWidget.php +++ b/src/Widgets/BlogArchiveWidget.php @@ -76,7 +76,7 @@ class BlogArchiveWidget extends Widget public function __construct($record = [], $creationType = DataObject::CREATE_OBJECT, $queryParams = []) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogArchiveWidgetController.php b/src/Widgets/BlogArchiveWidgetController.php index aa00c5d..41d4ed7 100644 --- a/src/Widgets/BlogArchiveWidgetController.php +++ b/src/Widgets/BlogArchiveWidgetController.php @@ -16,7 +16,7 @@ class BlogArchiveWidgetController extends WidgetController { public function __construct($widget = null) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogCategoriesWidget.php b/src/Widgets/BlogCategoriesWidget.php index 4d3d795..b886be9 100644 --- a/src/Widgets/BlogCategoriesWidget.php +++ b/src/Widgets/BlogCategoriesWidget.php @@ -61,7 +61,7 @@ class BlogCategoriesWidget extends Widget public function __construct($record = [], $creationType = DataObject::CREATE_OBJECT, $queryParams = []) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogCategoriesWidgetController.php b/src/Widgets/BlogCategoriesWidgetController.php index 755e0b1..55018ba 100644 --- a/src/Widgets/BlogCategoriesWidgetController.php +++ b/src/Widgets/BlogCategoriesWidgetController.php @@ -16,7 +16,7 @@ class BlogCategoriesWidgetController extends WidgetController { public function __construct($widget = null) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogFeaturedPostsWidget.php b/src/Widgets/BlogFeaturedPostsWidget.php index 4265813..4c2f409 100644 --- a/src/Widgets/BlogFeaturedPostsWidget.php +++ b/src/Widgets/BlogFeaturedPostsWidget.php @@ -60,7 +60,7 @@ class BlogFeaturedPostsWidget extends Widget public function __construct($record = [], $creationType = DataObject::CREATE_OBJECT, $queryParams = []) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogRecentPostsWidget.php b/src/Widgets/BlogRecentPostsWidget.php index b5d3729..c68f39d 100644 --- a/src/Widgets/BlogRecentPostsWidget.php +++ b/src/Widgets/BlogRecentPostsWidget.php @@ -60,7 +60,7 @@ class BlogRecentPostsWidget extends Widget public function __construct($record = [], $creationType = DataObject::CREATE_OBJECT, $queryParams = []) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogRecentPostsWidgetController.php b/src/Widgets/BlogRecentPostsWidgetController.php index 86410d1..c9eefaa 100644 --- a/src/Widgets/BlogRecentPostsWidgetController.php +++ b/src/Widgets/BlogRecentPostsWidgetController.php @@ -16,7 +16,7 @@ class BlogRecentPostsWidgetController extends WidgetController { public function __construct($widget = null) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogTagsCloudWidget.php b/src/Widgets/BlogTagsCloudWidget.php index c39a68c..55f550d 100644 --- a/src/Widgets/BlogTagsCloudWidget.php +++ b/src/Widgets/BlogTagsCloudWidget.php @@ -56,7 +56,7 @@ class BlogTagsCloudWidget extends Widget public function __construct($record = [], $creationType = DataObject::CREATE_OBJECT, $queryParams = []) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogTagsCloudWidgetController.php b/src/Widgets/BlogTagsCloudWidgetController.php index 3621a62..0214d9a 100644 --- a/src/Widgets/BlogTagsCloudWidgetController.php +++ b/src/Widgets/BlogTagsCloudWidgetController.php @@ -16,7 +16,7 @@ class BlogTagsCloudWidgetController extends WidgetController { public function __construct($widget = null) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogTagsWidget.php b/src/Widgets/BlogTagsWidget.php index b07ef1a..09dbfcd 100644 --- a/src/Widgets/BlogTagsWidget.php +++ b/src/Widgets/BlogTagsWidget.php @@ -61,7 +61,7 @@ class BlogTagsWidget extends Widget public function __construct($record = [], $creationType = DataObject::CREATE_OBJECT, $queryParams = []) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', diff --git a/src/Widgets/BlogTagsWidgetController.php b/src/Widgets/BlogTagsWidgetController.php index 5a89bd1..82c89f0 100644 --- a/src/Widgets/BlogTagsWidgetController.php +++ b/src/Widgets/BlogTagsWidgetController.php @@ -16,7 +16,7 @@ class BlogTagsWidgetController extends WidgetController { public function __construct($widget = null) { - Deprecation::withNoReplacement(function () { + Deprecation::withSuppressedNotice(function () { Deprecation::notice( '4.3.0', 'Will be removed without equivalent functionality to replace it', From 9127583774861f6b1d9caad16c5dccdad9e9b474 Mon Sep 17 00:00:00 2001 From: Steve Boyd Date: Mon, 23 Sep 2024 15:14:49 +1200 Subject: [PATCH 2/2] DEP Increase minimum version of silverstripe/framework --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 86d1f82..84ca2bc 100755 --- a/composer.json +++ b/composer.json @@ -9,7 +9,7 @@ "type": "silverstripe-vendormodule", "require": { "php": "^8.1", - "silverstripe/cms": "^5", + "silverstripe/cms": "^5.4", "silverstripe/lumberjack": "^3.0", "silverstripe/tagfield": "^3.0", "silverstripe/assets": "^2.0",