luci-base: luci.js: only use overrideMimeType when supported
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
This commit is contained in:
parent
a7bfaf9b0b
commit
4b941bce40
1 changed files with 3 additions and 1 deletions
|
@ -329,7 +329,9 @@
|
|||
opt.xhr.open(opt.method, opt.url, true);
|
||||
|
||||
opt.xhr.responseType = 'text';
|
||||
opt.xhr.overrideMimeType('application/octet-stream');
|
||||
|
||||
if ('overrideMimeType' in opt.xhr)
|
||||
opt.xhr.overrideMimeType('application/octet-stream');
|
||||
|
||||
if ('timeout' in opt)
|
||||
opt.xhr.timeout = +opt.timeout;
|
||||
|
|
Loading…
Reference in a new issue