dépôts
/
lhc
/
web
/
wiklou.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Merge "Inject LoadBalancer into GenderCache"
[lhc/web/wiklou.git]
/
includes
/
specials
/
SpecialWatchlist.php
diff --git
a/includes/specials/SpecialWatchlist.php
b/includes/specials/SpecialWatchlist.php
index
812f1b0
..
2443470
100644
(file)
--- a/
includes/specials/SpecialWatchlist.php
+++ b/
includes/specials/SpecialWatchlist.php
@@
-554,6
+554,9
@@
class SpecialWatchlist extends ChangesListSpecialPage {
$rc->numberofWatchingusers = 0;
}
$rc->numberofWatchingusers = 0;
}
+ // XXX: this treats pages with no unseen changes as "not on the watchlist" since
+ // everything is on the watchlist and it is an easy way to make pages with unseen
+ // changes appear bold. @TODO: clean this up.
$changeLine = $list->recentChangesLine( $rc, $unseen, $counter );
if ( $changeLine !== false ) {
$s .= $changeLine;
$changeLine = $list->recentChangesLine( $rc, $unseen, $counter );
if ( $changeLine !== false ) {
$s .= $changeLine;
@@
-865,19
+868,19
@@
class SpecialWatchlist extends ChangesListSpecialPage {
* @return bool User viewed the revision or a newer one
*/
protected function isChangeEffectivelySeen( RecentChange $rc ) {
* @return bool User viewed the revision or a newer one
*/
protected function isChangeEffectivelySeen( RecentChange $rc ) {
- $
lastVisitTs = $this->getLatestSeenTimestampIfHasUnseen
( $rc );
+ $
firstUnseen = $this->getLatestNotificationTimestamp
( $rc );
- return
$lastVisitTs === null || $lastVisitTs > $rc->getAttribute( 'rc_timestamp'
);
+ return
( $firstUnseen === null || $firstUnseen > $rc->getAttribute( 'rc_timestamp' )
);
}
/**
* @param RecentChange $rc
}
/**
* @param RecentChange $rc
- * @return string|null TS_MW timestamp o
r null if all revision were seen
+ * @return string|null TS_MW timestamp o
f first unseen revision or null if there isn't one
*/
*/
- private function getLatest
SeenTimestampIfHasUnseen
( RecentChange $rc ) {
+ private function getLatest
NotificationTimestamp
( RecentChange $rc ) {
return $this->watchStore->getLatestNotificationTimestamp(
$rc->getAttribute( 'wl_notificationtimestamp' ),
return $this->watchStore->getLatestNotificationTimestamp(
$rc->getAttribute( 'wl_notificationtimestamp' ),
- $
rc->getPerform
er(),
+ $
this->getUs
er(),
$rc->getTitle()
);
}
$rc->getTitle()
);
}