Skip to content

Commit

Permalink
corrected wrong slash separator in Encode URLs
Browse files Browse the repository at this point in the history
  • Loading branch information
sunbrn committed Dec 5, 2019
1 parent 1797f8d commit c221592
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -332,7 +332,7 @@ class EncodeDownloader extends Downloader {
new Thread {
override def run(): Unit = {
val fields = line.split("\t")
val candidateName = fields(url).split(File.separator).last
val candidateName = fields(url).split("/").last
val fileId = FileDatabase.fileId(datasetId, fields(url), stage, candidateName)
val fileNameAndCopyNumber = FileDatabase.getFileNameAndCopyNumber(fileId)

Expand All @@ -342,7 +342,7 @@ class EncodeDownloader extends Downloader {

val filePath = path + File.separator + filename

val candidateNameJson = fields(url).split(File.separator).last + ".json"
val candidateNameJson = fields(url).split("/").last + ".json"
val urlExperimentJson = source.url + dataset.getParameter("json_prefix").getOrElse("experiments/") + fields(experimentAccession) + dataset.getParameter("json_suffix").getOrElse("/?format=json")
val fileIdJson = FileDatabase.fileId(datasetId, urlExperimentJson, stage, candidateNameJson, false)
FileDatabase.checkIfUpdateFile(fileIdJson, fields(md5sum), fields(originSize), fields(originLastUpdate))
Expand Down

0 comments on commit c221592

Please sign in to comment.