fx-compat: Simplify Zotero.File.download()
`NetUtil.newChannel()` can take a string spec, so don't bother parsing
to an nsIURI first
Follow-up to 7adb8fd150
This commit is contained in:
parent
7adb8fd150
commit
1a1a5924da
1 changed files with 1 additions and 2 deletions
|
@ -459,9 +459,8 @@ Zotero.File = new function(){
|
|||
}
|
||||
|
||||
var deferred = Zotero.Promise.defer();
|
||||
const uri_ = NetUtil.newURI(uri);
|
||||
const inputChannel = NetUtil.newChannel({
|
||||
uri: uri_,
|
||||
uri,
|
||||
loadUsingSystemPrincipal: true
|
||||
});
|
||||
const outputChannel = FileUtils.openSafeFileOutputStream(new FileUtils.File(path));
|
||||
|
|
Loading…
Add table
Reference in a new issue