From d6b44f2385db141a428c35a48b3bf6c17f85e43c Mon Sep 17 00:00:00 2001 From: Sabina Talipova Date: Fri, 9 Dec 2022 16:24:48 +1300 Subject: [PATCH] DEP PHP Support in CMS5 --- _config.php | 3 --- composer.json | 10 +++++----- src/Controllers/CommentingController.php | 8 +------- tests/CommentsExtensionTest.php | 4 ++-- 4 files changed, 8 insertions(+), 17 deletions(-) delete mode 100644 _config.php diff --git a/_config.php b/_config.php deleted file mode 100644 index 2fcbaa6..0000000 --- a/_config.php +++ /dev/null @@ -1,3 +0,0 @@ -setMaxAge(0); @@ -528,7 +524,5 @@ class CommentingController extends Controller if (Director::is_site_url($url)) { return $this->redirect($url); } - - return false; } } diff --git a/tests/CommentsExtensionTest.php b/tests/CommentsExtensionTest.php index 142f0f1..c31798b 100644 --- a/tests/CommentsExtensionTest.php +++ b/tests/CommentsExtensionTest.php @@ -232,7 +232,7 @@ class CommentsExtensionTest extends FunctionalTest public function testGetCommentRSSLink() { - Config::modify()->merge('SilverStripe\\Control\\Director', 'alternate_base_url', 'http://unittesting.local'); + Config::modify()->set('SilverStripe\\Control\\Director', 'alternate_base_url', 'http://unittesting.local'); $item = $this->objFromFixture(CommentableItem::class, 'first'); $link = $item->getCommentRSSLink(); @@ -241,7 +241,7 @@ class CommentsExtensionTest extends FunctionalTest public function testGetCommentRSSLinkPage() { - Config::modify()->merge('SilverStripe\\Control\\Director', 'alternate_base_url', 'http://unittesting.local'); + Config::modify()->set('SilverStripe\\Control\\Director', 'alternate_base_url', 'http://unittesting.local'); $item = $this->objFromFixture(CommentableItem::class, 'first'); $page = $item->getCommentRSSLinkPage();