Skip to content

Commit

Permalink
Merge branch 'release/1.3.1'
Browse files Browse the repository at this point in the history
  • Loading branch information
Zack Siri committed Feb 17, 2018
2 parents 5139416 + 1994e28 commit 0b6ba5c
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 11 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ by adding `upstream` to your list of dependencies in `mix.exs`:

```elixir
def deps do
[{:upstream, "~> 1.3.0"}]
[{:upstream, "~> 1.3.1"}]
end
```

Expand Down
2 changes: 1 addition & 1 deletion lib/upstream/b2/large_file/unfinished.ex
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ defmodule Upstream.B2.LargeFile.Unfinished do

use Upstream.B2.Base

def url(_), do: Url.generate(Account.api_url(), :list_unfinished_large_files)
def url(_), do: Url.generate(Account.api_url(), :list_unfinished_large_files)

def body(_) do
%{bucketId: Upstream.config(:bucket_id)}
Expand Down
10 changes: 3 additions & 7 deletions lib/upstream/router.ex
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ defmodule Upstream.Router do
plug(:dispatch)

get "/chunks/unfinished" do
case B2.LargeFile.Unfinished.call do
case B2.LargeFile.Unfinished.call() do
{:ok, unfinished} ->
render_json(conn, 200, unfinished)

Expand All @@ -36,7 +36,7 @@ defmodule Upstream.Router do
{:ok, %B2.LargeFile.ListParts{parts: parts}} ->
shas = B2.LargeFile.ListParts.extract_shas(parts)
render_json(conn, 200, %{shas: shas})

{:error, reason} ->
render_json(conn, 422, reason)
end
Expand Down Expand Up @@ -103,15 +103,11 @@ defmodule Upstream.Router do
end
end

require IEx
patch "/chunks/add" do
IEx.pry

%{"file_id" => file_id, "part_number" => part_number, "chunk_size" => chunk_size} =
conn.body_params

%{path: path,
filename: _filename} = conn.body_params[Upstream.file_param()]
%{path: path, filename: _filename} = conn.body_params[Upstream.file_param()]

upload_params = %{
file_id: file_id,
Expand Down
1 change: 0 additions & 1 deletion lib/upstream/worker/chunk.ex
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ defmodule Upstream.Worker.Chunk do
def task(state) do
with {:ok, checksum} <- Checksum.start_link(),
{:ok, part_url} <- Upload.part_url(state.uid.file_id) do

index = state.uid.index

header = %{
Expand Down
2 changes: 1 addition & 1 deletion mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ defmodule Upstream.Mixfile do
def project do
[
app: :upstream,
version: "1.3.0",
version: "1.3.1",
elixir: "~> 1.6.0",
build_embedded: Mix.env() == :prod,
start_permanent: Mix.env() == :prod,
Expand Down

0 comments on commit 0b6ba5c

Please sign in to comment.