TinyMCE wpView: prevent errors when pasting multiple non-embeddable URLs, props avryl, fixes #29268
git-svn-id: https://develop.svn.wordpress.org/trunk@29571 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
208645191d
commit
362e24eca7
|
@ -561,6 +561,8 @@ window.wp = window.wp || {};
|
||||||
setNodes: function () {
|
setNodes: function () {
|
||||||
if ( this.parsed ) {
|
if ( this.parsed ) {
|
||||||
this.setIframes( this.parsed );
|
this.setIframes( this.parsed );
|
||||||
|
} else if ( this.parsed === false ) {
|
||||||
|
this.setContent( '<p>' + this.original + '</p>', 'replace' );
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
@ -574,6 +576,9 @@ window.wp = window.wp || {};
|
||||||
shortcode: this.shortcode.string()
|
shortcode: this.shortcode.string()
|
||||||
}
|
}
|
||||||
} )
|
} )
|
||||||
|
.always( function() {
|
||||||
|
self.parsed = false;
|
||||||
|
} )
|
||||||
.done( function( response ) {
|
.done( function( response ) {
|
||||||
if ( response ) {
|
if ( response ) {
|
||||||
self.parsed = response;
|
self.parsed = response;
|
||||||
|
|
Loading…
Reference in New Issue