mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/DiscussionTools
synced 2024-11-24 08:23:52 +00:00
DiscussionToolsHooks: Only enable when viewing pages
Previously we'd also run on action=history, action=info etc. (which did nothing). Change-Id: I4bd10311a91433f357a6f5506c65364d399f3915
This commit is contained in:
parent
f92e07687f
commit
3bd513374e
|
@ -57,9 +57,8 @@ class DiscussionToolsHooks {
|
|||
);
|
||||
|
||||
if (
|
||||
// Don't show on edit pages
|
||||
$actionName !== 'edit' &&
|
||||
$actionName !== 'submit' &&
|
||||
// Don't show on edit pages, history, etc.
|
||||
$actionName === 'view' &&
|
||||
// Only wikitext pages (e.g. not Flow boards)
|
||||
$title->getContentModel() === CONTENT_MODEL_WIKITEXT &&
|
||||
(
|
||||
|
|
Loading…
Reference in a new issue