public function getEditNotices(Title $title, $oldid, array &$notices)
 {
     // HACK: EditPage invokes addToEditView() before this function, so $this->noticesDone
     // will only be true if we're being called by EditPage, in which case we need to do nothing
     // to avoid duplicating the notices.
     $this->load();
     if ($this->noticesDone || !$this->article->isReviewable()) {
         return;
     }
     // HACK fake EditPage
     $editPage = new EditPage(new Article($title, $oldid));
     $editPage->oldid = $oldid;
     $reqUser = $this->getUser();
     // HACK this duplicates logic from addToEditView()
     $log = $this->stabilityLogNotice(false);
     if ($log) {
         $notices[$this->article->isPageLocked() ? 'revreview-locked' : 'revreview-unlocked'] = $log;
     } else {
         if ($this->editWillRequireReview($editPage)) {
             $notices['revreview-editnotice'] = $this->msg('revreview-editnotice')->parseAsBlock();
         }
     }
     $frev = $this->article->getStableRev();
     if ($frev && $this->article->revsArePending()) {
         $revsSince = $this->article->getPendingRevCount();
         $pendingMsg = FlaggedRevsXML::pendingEditNoticeMessage($this->article, $frev, $revsSince);
         $notices[$pendingMsg->getKey()] = '<div class="plainlinks">' . $pendingMsg->parseAsBlock() . '</div>';
     }
     $latestId = $this->article->getLatest();
     $revId = $oldid ? $oldid : $latestId;
     if ($frev && $frev->getRevId() < $latestId && $reqUser->getBoolOption('flaggedrevseditdiffs') && $revId === $latestId) {
         // Construct a link to the diff
         $diffUrl = $this->article->getTitle()->getFullURL(array('diff' => $revId, 'oldid' => $frev->getRevId()));
         $notices['review-edit-diff'] = $this->msg('review-edit-diff')->parse() . ' ' . FlaggedRevsXML::diffToggle($diffUrl);
     }
 }