See #170: dispatch / handle delete and update on Audio

This commit is contained in:
Eliot Berriot 2020-04-08 15:59:06 +02:00
parent b04ba47a38
commit 8c93169d94
No known key found for this signature in database
GPG key ID: 6B501DFD73514E14
7 changed files with 255 additions and 9 deletions

View file

@ -277,3 +277,18 @@ def get_object_by_fid(fid, local=None):
return channel
return instance
def can_manage(obj_owner, actor):
if not obj_owner:
return False
if not actor:
return False
if obj_owner == actor:
return True
if obj_owner.domain.service_actor == actor:
return True
return False