Skip to content

Commit 3e3fc0d

Browse files
committed
Limit noop converter to script type
Signed-off-by: Sean Robinson <[email protected]>
1 parent 274f3e6 commit 3e3fc0d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/ajax.js

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -743,9 +743,9 @@ jQuery.extend( {
743743
response = ajaxHandleResponses( s, jqXHR, responses );
744744
}
745745

746-
// Use a noop converter for bad returns
747-
if ( !isSuccess ) {
748-
s.converters[ "text " + s.dataType ] = function() {};
746+
// Use a noop converter for missing script
747+
if ( !isSuccess && s.dataType === "script" ) {
748+
s.converters[ "text script" ] = function() {};
749749
}
750750

751751
// Convert no matter what (that way responseXXX fields are always set)

0 commit comments

Comments
 (0)