Regex should be non-greedy, see #28389

Built from https://develop.svn.wordpress.org/trunk@28615


git-svn-id: http://core.svn.wordpress.org/trunk@28439 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Andrew Ozz 2014-05-29 07:56:14 +00:00
parent 500bfe7a54
commit e518fda253
3 changed files with 2 additions and 2 deletions

View File

@ -945,7 +945,7 @@ tinymce.PluginManager.add( 'wpeditimage', function( editor ) {
// Remove toolbar from undo levels
editor.on( 'BeforeAddUndo', function( event ) {
event.level.content = event.level.content.replace( /<p [^>]*data-mce-bogus[^>]+>[\s\S]*<\/p>/g, '' );
event.level.content = event.level.content.replace( /<p [^>]*data-mce-bogus[^>]+>[\s\S]*?<\/p>/g, '' );
});
editor.on( 'cut', function() {

File diff suppressed because one or more lines are too long