mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/VisualEditor
synced 2024-11-25 14:56:20 +00:00
Merge "Wikitext paste: Fail if result has no visible content"
This commit is contained in:
commit
2104ee1590
|
@ -106,6 +106,10 @@ ve.ui.MWWikitextStringTransferHandler.prototype.process = function () {
|
|||
null // No sanitization, since HTML is from Parsoid
|
||||
);
|
||||
|
||||
if ( !doc.data.hasContent() ) {
|
||||
return failure();
|
||||
}
|
||||
|
||||
// Attempt to undo outermost p-wrapping if possible
|
||||
surface = new ve.dm.Surface( doc );
|
||||
try {
|
||||
|
|
Loading…
Reference in a new issue