Fix #2534: Address @jashkenas review comment.
This commit is contained in:
parent
ec59a626f2
commit
78423e9a14
|
@ -18,10 +18,10 @@ return unless window?
|
|||
|
||||
# Load a remote script from the current domain via XHR.
|
||||
CoffeeScript.load = (url, callback) ->
|
||||
if window.ActiveXObject
|
||||
xhr = new window.ActiveXObject('Microsoft.XMLHTTP')
|
||||
xhr = if window.ActiveXObject
|
||||
new window.ActiveXObject('Microsoft.XMLHTTP')
|
||||
else
|
||||
xhr = new XMLHttpRequest()
|
||||
new XMLHttpRequest()
|
||||
xhr.open 'GET', url, true
|
||||
xhr.overrideMimeType 'text/plain' if 'overrideMimeType' of xhr
|
||||
xhr.onreadystatechange = ->
|
||||
|
|
Loading…
Reference in New Issue