From cd91fd8c9ef689cbc027b631c00631bf3fedd6e7 Mon Sep 17 00:00:00 2001 From: parasprite Date: Sat, 24 Oct 2020 17:01:33 -0700 Subject: [PATCH] Allows assistants to update tags on deleted images (#58) Co-authored-by: Raptorshy --- lib/philomena/users/ability.ex | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/philomena/users/ability.ex b/lib/philomena/users/ability.ex index a8cedb88..f30f116e 100644 --- a/lib/philomena/users/ability.ex +++ b/lib/philomena/users/ability.ex @@ -177,6 +177,9 @@ defimpl Canada.Can, for: [Atom, Philomena.Users.User] do def can?(%User{role: "assistant", role_map: %{"Image" => "moderator"}}, :edit, %Image{}), do: true + def can?(%User{role: "assistant", role_map: %{"Image" => "moderator"}}, :edit_metadata, %Image{}), + do: true + def can?( %User{role: "assistant", role_map: %{"Image" => "moderator"}}, :edit_description,