Skip to content

Commit

Permalink
Refactor a variable.
Browse files Browse the repository at this point in the history
  • Loading branch information
VJalili committed Aug 3, 2018
1 parent 6c62cc5 commit f2d1db9
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions lib/galaxy/managers/cloud.py
Original file line number Diff line number Diff line change
Expand Up @@ -294,16 +294,16 @@ def download(self, trans, history_id, provider, bucket, credentials, dataset_ids
if hda.deleted or hda.purged or hda.state != "ok" or hda.creating_job.tool_id == DOWNLOAD_TOOL:
continue
if dataset_ids is None or hda.dataset.id in dataset_ids:
args_file = os.path.abspath(os.path.join(
credentials_file = os.path.abspath(os.path.join(
trans.app.config.new_file_path,
"cd_" + ''.join(random.SystemRandom().choice(
string.ascii_uppercase + string.digits) for _ in range(11))))
with open(args_file, "w") as f:
with open(credentials_file, "w") as f:
f.write(json.dumps(credentials))
object_label = hda.name.replace(" ", "_")
args = {
"provider": provider,
"credentials_file": args_file,
"credentials_file": credentials_file,
"bucket": bucket,
"object_label": object_label,
"filename": hda.dataset.get_file_name(),
Expand Down

0 comments on commit f2d1db9

Please sign in to comment.