Skip to content
This repository has been archived by the owner on Nov 13, 2024. It is now read-only.

Commit

Permalink
allow admin to delete individuals with public sightings
Browse files Browse the repository at this point in the history
  • Loading branch information
naknomum committed Oct 23, 2023
1 parent 36fedb3 commit bbad663
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions app/modules/users/permissions/rules.py
Original file line number Diff line number Diff line change
Expand Up @@ -532,6 +532,12 @@ def _permitted_as_public_data(self):
and (
self._action == AccessOperation.READ
or self._action == AccessOperation.WRITE
or (
# houston issue #876 allows for admin to delete individuals with public sightings
self._action == AccessOperation.DELETE
and self._user.is_admin
and self._obj.__class__.__name__ == 'Individual'
)
)
)

Expand Down

0 comments on commit bbad663

Please sign in to comment.