diff --git a/wp-includes/js/tinymce/plugins/wordpress/editor_plugin_src.js b/wp-includes/js/tinymce/plugins/wordpress/editor_plugin_src.js index 9fecbc4c3f..bdf8851b76 100644 --- a/wp-includes/js/tinymce/plugins/wordpress/editor_plugin_src.js +++ b/wp-includes/js/tinymce/plugins/wordpress/editor_plugin_src.js @@ -217,12 +217,11 @@ }); ed.onSaveContent.add(function(ed, o) { - if ( ed.getParam('wpautop', true) && typeof(switchEditors) == 'object' ) { - if ( ed.isHidden() ) - o.content = o.element.value; - else - o.content = switchEditors.pre_wpautop(o.content); - } + // If editor is hidden, we just want the textarea's value to be saved + if ( ed.isHidden() ) + o.content = o.element.value; + else if ( ed.getParam('wpautop', true) && typeof(switchEditors) == 'object' ) + o.content = switchEditors.pre_wpautop(o.content); }); /* disable for now