r107449 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r107448‎ | r107449 | r107450 >
Date:22:50, 27 December 2011
Author:tstarling
Status:ok (Comments)
Tags:
Comment:
Revert the fix for bug 32858 (r105664, r105161, r103476): no consensus, backwards compatibility issues not addressed (e.g. {{selfsubst/now string}})
Modified paths:
  • /trunk/phase3/RELEASE-NOTES-1.19 (modified) (history)
  • /trunk/phase3/includes/WikiPage.php (modified) (history)

Diff [purge]

Index: trunk/phase3/RELEASE-NOTES-1.19
@@ -163,8 +163,6 @@
164164 * (bug 32168) Add wfAssembleUrl for use in wfExpandUrl.
165165 * (bug 32168) fixed - wfExpandUrl expands dot segments now.
166166 * (bug 31535) Upload comments now truncated properly, and don't have brackets.
167 -* (bug 32858) Do not register links, categories, etc. from CSS/JS pages in the
168 - database.
169167 * (bug 32086) Special:PermanentLink now show an error message when no subpage
170168 was specified.
171169 * (bug 30368) Special:Newpages now shows the new page name for moved pages.
Index: trunk/phase3/includes/WikiPage.php
@@ -2021,18 +2021,7 @@
20222022 $edit->newText = $text;
20232023 $edit->pst = $wgParser->preSaveTransform( $text, $this->mTitle, $user, $popts );
20242024 $edit->popts = $this->makeParserOptions( 'canonical' );
2025 -
2026 - // Bug 32858: For a CSS/JS page, put a blank parser output into the
2027 - // prepared edit, so that links etc. won't be registered in the
2028 - // database. We could have set $edit->output to false or something if
2029 - // we thought of this bug earlier, but now that would break the
2030 - // interface with AbuseFilter etc.
2031 - if ( $this->mTitle->isCssOrJsPage() || $this->getTitle()->isCssJsSubpage() ) {
2032 - $input = '';
2033 - } else {
2034 - $input = $edit->pst;
2035 - }
2036 - $edit->output = $wgParser->parse( $input, $this->mTitle, $edit->popts, true, true, $revid );
 2025+ $edit->output = $wgParser->parse( $edit->pst, $this->mTitle, $edit->popts, true, true, $revid );
20372026 $edit->oldText = $this->getRawText();
20382027
20392028 $this->mPreparedEdit = $edit;

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r103476(bug 32450) MediaWiki: .js|.css pages parsed [[Category:#]] links...hashar16:46, 17 November 2011
r105161Skip replaceInternalLinks2 for js/css pages...hashar10:14, 5 December 2011
r105664* Revert r103476, r105161 and implement the fix for bug 32858 (a.k.a. bug 324......tstarling10:32, 9 December 2011

Comments

#Comment by Tim Starling (talk | contribs)   22:53, 27 December 2011

Actually that subst thing would have worked either way, but there were better examples of backwards compatibility issues on the bug report, for example __NOINDEX__ and deletion request templates.

Status & tagging log