mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/InputBox
synced 2024-11-23 22:54:02 +00:00
Merge "De-obfuscate attempts to trick people into editing .js pages"
This commit is contained in:
commit
d19b359312
|
@ -684,6 +684,12 @@ class InputBox {
|
|||
if ( !$this->isValidColor( $this->mBGColor ) ) {
|
||||
$this->mBGColor = 'transparent';
|
||||
}
|
||||
|
||||
// T297725: De-obfuscate attempts to trick people into making edits to .js pages
|
||||
$target = $this->mType === 'commenttitle' ? $this->mPage : $this->mDefaultText;
|
||||
if ( $this->mHidden && $this->mPreload && substr( $target, -3 ) === '.js' ) {
|
||||
$this->mHidden = false;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue