Commit 02646074 authored by Geoffrey Métais's avatar Geoffrey Métais

Remove any slash from subtitles download URLs

parent 39f6172b
......@@ -324,7 +324,10 @@ public class SubtitlesDownloader {
if (mToken == null || path == null) return;
final StringBuilder sb = new StringBuilder();
final String name = fileName.lastIndexOf('.') > 0 ? fileName.substring(0, fileName.lastIndexOf('.')) : fileName;
sb.append(SUBTITLES_DIRECTORY.getPath()).append('/').append(name.replace("/", "")).append('.').append(language).append('.').append(subFormat);
sb.append(SUBTITLES_DIRECTORY.getPath())
.append('/').append(name.replace("/", ""))
.append('.').append(language.replace("/", ""))
.append('.').append(subFormat.replace("/", ""));
final String srtUrl = sb.toString();
FileOutputStream f = null;
GZIPInputStream gzIS = null;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment