Make deleting an actor ignoring error when deleting files
Signed-off-by: Thomas Citharel <tcit@tcit.fr>
This commit is contained in:
parent
f84cc299ba
commit
bfb04bb84d
@ -1343,6 +1343,7 @@ defmodule Mobilizon.Actors do
|
||||
|
||||
defp remove_banner(%Actor{banner: %File{url: url}} = actor) do
|
||||
safe_remove_file(url, actor)
|
||||
{:ok, actor}
|
||||
end
|
||||
|
||||
@spec remove_avatar(Actor.t()) :: {:ok, Actor.t()}
|
||||
@ -1350,6 +1351,7 @@ defmodule Mobilizon.Actors do
|
||||
|
||||
defp remove_avatar(%Actor{avatar: %File{url: url}} = actor) do
|
||||
safe_remove_file(url, actor)
|
||||
{:ok, actor}
|
||||
end
|
||||
|
||||
@spec safe_remove_file(String.t(), Actor.t()) :: {:ok, Actor.t()}
|
||||
|
Loading…
Reference in New Issue
Block a user