From 0fa3196e8b16099b2a64570ac429bc0dbd53d1b8 Mon Sep 17 00:00:00 2001 From: Sam Wilson Date: Mon, 23 Apr 2018 12:40:54 +0800 Subject: [PATCH] Use new Special:Log?logid=xxx URL for notification link Avoid redirecting via Special:Redirect/logid/xxx with the new logid parameter to Special:Log. Bug: T191608 Depends-On: I5f2e52531cd2ba617a25570e40aa8c5168e284d9 Change-Id: Iffb1b0d9cc44fde69aa53f32d4a066cd3a10c5f4 --- includes/EchoCoreThanksPresentationModel.php | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/EchoCoreThanksPresentationModel.php b/includes/EchoCoreThanksPresentationModel.php index cc2c211f..625c92cd 100644 --- a/includes/EchoCoreThanksPresentationModel.php +++ b/includes/EchoCoreThanksPresentationModel.php @@ -96,9 +96,9 @@ class EchoCoreThanksPresentationModel extends EchoEventPresentationModel { } public function getPrimaryLink() { - if ( $this->event->getExtraParam( 'logid' ) ) { - $logId = $this->event->getExtraParam( 'logid' ); - $url = Title::newFromText( "Special:Redirect/logid/$logId" )->getCanonicalURL(); + $logId = $this->event->getExtraParam( 'logid' ); + if ( $logId ) { + $url = SpecialPage::getTitleFor( 'Log' )->getLocalURL( [ 'logid' => $logId ] ); $label = 'notification-link-text-view-logentry'; } else { $url = $this->event->getTitle()->getLocalURL( [