Fix content type and size missing for profile avatars

Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
Thomas Citharel 2021-04-09 10:43:34 +02:00
parent b34958d3af
commit e991d7d373
No known key found for this signature in database
GPG Key ID: A061B9DDE0CA0773
1 changed files with 2 additions and 2 deletions

View File

@ -225,9 +225,9 @@ defmodule Mobilizon.GraphQL.Resolvers.Person do
end
defp save_picture(media, key) do
with {:ok, %{name: name, url: url, content_type: content_type, size: _size}} <-
with {:ok, %{name: name, url: url, content_type: content_type, size: size}} <-
Upload.store(media.file, type: key, description: media.alt) do
%{"name" => name, "url" => url, "mediaType" => content_type}
%{"name" => name, "url" => url, "content_type" => content_type, "size" => size}
end
end