mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-29 00:30:44 +00:00
Merge "Escape ampersands in entities from plain text DOM content"
This commit is contained in:
commit
da4a2e13d1
|
@ -189,7 +189,9 @@ WSP.escapeWikiText = function ( state, text ) {
|
|||
// push out the original source
|
||||
// XXX: This assumes the content was not
|
||||
// modified for now.
|
||||
outTexts.push( token.dataAttribs.src );
|
||||
outTexts.push( token.dataAttribs.src
|
||||
// escape ampersands in entity text
|
||||
.replace(/&(#?[0-9a-zA-Z]{2,6};)/, '&$1') );
|
||||
// skip generated tokens
|
||||
for ( ; i < l; i ++) {
|
||||
var tk = tokens[i];
|
||||
|
|
Loading…
Reference in a new issue