People following links from their watchlist emails to since-deleted
revisions were getting fatals from
WatchedItemStore::getNotificationTimestamp().
It's hard to tell whether returning null or false is the right thing to
do here, because this function can return both and the difference is not
documented, and I wasn't able to find any callers that care about the
distinction.
Bug: T226741
Change-Id: Ib2a836099343f4c161227266dbeeafbc76dccc2b
}
$oldRev = $this->revisionLookup->getRevisionById( $oldid );
+ if ( !$oldRev ) {
+ // Oldid given but does not exist (probably deleted)
+ return false;
+ }
+
$nextRev = $this->revisionLookup->getNextRevision( $oldRev );
if ( !$nextRev ) {
// Oldid given and is the latest revision for this title; clear the timestamp.