Skip to content

Commit d2df76d

Browse files
committed
episode_downloader: expand download directory path
1 parent d22a0ac commit d2df76d

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/sips_downloader/episode_downloader.ex

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ defmodule SipsDownloader.EpisodeDownloader do
2222
defp process_download(work = {name, _url}, state = %{fh: nil, dir: dir}) do
2323
receive do
2424
%HTTPoison.AsyncStatus{code: 200} ->
25-
{:ok, fh} = Path.join(dir, name) |> Kernel.<>(".tmp") |> File.open([:write, :append])
25+
{:ok, fh} = Path.expand(dir) |> Path.join(name) |> Kernel.<>(".tmp") |> File.open([:write, :append])
2626
process_download(work, %{state | fh: fh})
2727

2828
%HTTPoison.AsyncStatus{code: 302} ->

0 commit comments

Comments
 (0)