Remove DifferenceEngine::getDiffBodyCacheKey

It has been deprecated since 1.31 and it is unused.

Change-Id: Ia2473ba8b5e68b884ec0ee0464147c3a063eb45e
This commit is contained in:
Matěj Suchánek 2022-11-13 15:37:10 +01:00
parent 3482ce559c
commit 81f69c23dc
2 changed files with 3 additions and 28 deletions

View file

@ -194,6 +194,8 @@ because of Phabricator reports.
* DifferenceEngine::textDiff(), deprecated since 1.32, has been removed.
* Skin::getSearchPageTitle() and Skin::setSearchPageTitle(), deprecated since
1.38, have been removed.
* DifferenceEngine::getDiffBodyCacheKey(), deprecated since 1.31, has been
removed.
* …
=== Deprecations in 1.40 ===

View file

@ -1174,21 +1174,7 @@ class DifferenceEngine extends ContextSource {
$cache = $services->getMainWANObjectCache();
$stats = $services->getStatsdDataFactory();
if ( $this->mOldid && $this->mNewid ) {
// Check if subclass is still using the old way
// for backwards-compatibility
$detected = MWDebug::detectDeprecatedOverride(
$this,
__CLASS__,
'getDiffBodyCacheKey',
'1.31'
);
$key = null;
if ( $detected ) {
$key = $this->getDiffBodyCacheKey();
}
if ( $key === null ) {
$key = $cache->makeKey( ...$this->getDiffBodyCacheKeyParams() );
}
// Try cache
if ( !$this->mRefreshCache ) {
@ -1353,19 +1339,6 @@ class DifferenceEngine extends ContextSource {
$this->mNewid = 987654321;
// This will repeat a bunch of unnecessary key fields for each slot. Not nice but harmless.
$detected = MWDebug::detectDeprecatedOverride(
$this,
__CLASS__,
'getDiffBodyCacheKey',
'1.31'
);
if ( $detected ) {
$cacheString = $this->getDiffBodyCacheKey();
if ( $cacheString ) {
return [ $cacheString ];
}
}
$params = $this->getDiffBodyCacheKeyParams();
// Try to get rid of the standard keys to keep the cache key human-readable: