mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools
synced 2024-11-27 17:51:09 +00:00
Enable visualenhancements on archived talk pages
Bug: T374198 Change-Id: I50f566934bd0f3962741557ca24f1ef4af288eee
This commit is contained in:
parent
d7924d8e17
commit
3dc503c43b
|
@ -320,12 +320,12 @@ class HookUtils {
|
||||||
}
|
}
|
||||||
|
|
||||||
// ARCHIVEDTALK/NOTALK magic words
|
// ARCHIVEDTALK/NOTALK magic words
|
||||||
if ( self::hasPagePropCached( $title, 'notalk' ) ) {
|
if ( static::hasPagePropCached( $title, 'notalk' ) ) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
if (
|
if (
|
||||||
$feature === static::REPLYTOOL &&
|
$feature === static::REPLYTOOL &&
|
||||||
self::hasPagePropCached( $title, 'archivedtalk' )
|
static::hasPagePropCached( $title, 'archivedtalk' )
|
||||||
) {
|
) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -336,8 +336,11 @@ class HookUtils {
|
||||||
$dtConfig = MediaWikiServices::getInstance()->getConfigFactory()->makeConfig( 'discussiontools' );
|
$dtConfig = MediaWikiServices::getInstance()->getConfigFactory()->makeConfig( 'discussiontools' );
|
||||||
// Visual enhancements are only enabled on talk namespaces (T325417) ...
|
// Visual enhancements are only enabled on talk namespaces (T325417) ...
|
||||||
return $title->isTalkPage() || (
|
return $title->isTalkPage() || (
|
||||||
// ... or __NEWSECTIONLINK__ pages (T331635)
|
// ... or __NEWSECTIONLINK__ (T331635) or __ARCHIVEDTALK__ (T374198) pages
|
||||||
static::hasPagePropCached( $title, 'newsectionlink' ) &&
|
(
|
||||||
|
static::hasPagePropCached( $title, 'newsectionlink' ) ||
|
||||||
|
static::hasPagePropCached( $title, 'archivedtalk' )
|
||||||
|
) &&
|
||||||
// excluding the main namespace, unless it has been configured for signatures
|
// excluding the main namespace, unless it has been configured for signatures
|
||||||
(
|
(
|
||||||
!$title->inNamespace( NS_MAIN ) ||
|
!$title->inNamespace( NS_MAIN ) ||
|
||||||
|
|
Loading…
Reference in a new issue