jenkins-bot has submitted this change and it was merged.
Change subject: Method to identify if a ChangesList is watchlist or normal
......................................................................
Method to identify if a ChangesList is watchlist or normal
There are differences, like grouping, between watchlist and
normal rendering that hook recipients need to know about.
This exposes if the setWatchlistDivs method has been called
which currently happens immediatly after instantiation in
SpecialWatchlist
Change-Id: Ibc06c6d9b878cad3f5da92cfbe3f650ad3f63efa
---
M includes/changes/ChangesList.php
1 file changed, 8 insertions(+), 0 deletions(-)
Approvals:
Siebrand: Looks good to me, approved
jenkins-bot: Verified
diff --git a/includes/changes/ChangesList.php b/includes/changes/ChangesList.php
index b996894..ca9efc3 100644
--- a/includes/changes/ChangesList.php
+++ b/includes/changes/ChangesList.php
@@ -81,6 +81,14 @@
}
/**
+ * @return bool true when setWatchlistDivs has been called
+ * @since 1.23
+ */
+ public function isWatchlist() {
+ return (bool)$this->watchlist;
+ }
+
+ /**
* As we use the same small set of messages in various methods and that
* they are called often, we call them once and save them in
$this->message
*/
--
To view, visit https://gerrit.wikimedia.org/r/117466
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: Ibc06c6d9b878cad3f5da92cfbe3f650ad3f63efa
Gerrit-PatchSet: 4
Gerrit-Project: mediawiki/core
Gerrit-Branch: master
Gerrit-Owner: EBernhardson <[email protected]>
Gerrit-Reviewer: Siebrand <[email protected]>
Gerrit-Reviewer: Umherirrender <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits