mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/AbuseFilter.git
synced 2024-11-23 21:53:35 +00:00
Use ::getLocalUrl instead of ::getFullUrl for HideAbuseLog form
Why: * The AbuseFilter Special:AbuseLog/hide page has a form that allows those with sufficent rights to hide abuse filter log entries. * This form defines a custom action, which uses a URL including the wgServer by calling ::getFullUrl. * When on WMF wikis and using mobile view, the domain name includes 'm' and as such the wgServer is not the correct URL for the form action in this case. * HTMLForm by default uses ::getLocalUrl for the action and as such Special:AbuseLog/hide should also use ::getLocalUrl to prevent these issues. What: * Change the call to ::getFullUrl in HideAbuseLog::show for the action text for the HTMLForm instance to instead be a call to ::getLocalUrl. Bug: T355012 Change-Id: I6c909d5e6724dd620cf656c9a55439ed5d5c2fb4
This commit is contained in:
parent
947e437566
commit
1c0a5b9c6f
|
@ -113,7 +113,7 @@ class HideAbuseLog extends AbuseFilterView {
|
|||
],
|
||||
];
|
||||
|
||||
$actionURL = $this->getTitle( 'hide' )->getFullURL( [ 'hideids' => array_fill_keys( $this->hideIDs, 1 ) ] );
|
||||
$actionURL = $this->getTitle( 'hide' )->getLocalURL( [ 'hideids' => array_fill_keys( $this->hideIDs, 1 ) ] );
|
||||
HTMLForm::factory( 'ooui', $formInfo, $this->getContext() )
|
||||
->setAction( $actionURL )
|
||||
->setWrapperLegend( $this->msg( 'abusefilter-log-hide-legend' )->text() )
|
||||
|
|
Loading…
Reference in a new issue