From ffbcb9a0c8831d9a02c8966f40a0f76840d73c75 Mon Sep 17 00:00:00 2001 From: Dylan Wagstaff Date: Thu, 5 Jul 2018 09:55:45 +1200 Subject: [PATCH] Deprecate alternatePreviewLink function as per CMS SilverStripe CMS 4.0.0 issues a deprecation notice before calling alternatePreviewLink on any page that hasMethod (i.e. is applied via an extension such as SiteTreeSubsites). Instead of double-issuing a notice, we will just mark this as deprecated in the next minor version via docblocks. --- src/Extensions/SiteTreeSubsites.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/Extensions/SiteTreeSubsites.php b/src/Extensions/SiteTreeSubsites.php index 488fef6..9500211 100644 --- a/src/Extensions/SiteTreeSubsites.php +++ b/src/Extensions/SiteTreeSubsites.php @@ -399,6 +399,8 @@ class SiteTreeSubsites extends DataExtension /** * This function is marked as deprecated for removal in 5.0.0 in silverstripe/cms * so now simply passes execution to where the functionality exists for backwards compatiblity. + * CMS 4.0.0 SiteTree already throws a SilverStripe deprecation error before calling this function. + * @deprecated 2.2...3.0 use updatePreviewLink instead * * @param string|null $action * @return string