Revert "Merge pull request 'feat: add multi-ID delete support with per-ID results' (#63) from fix/issue-47 into main"

This reverts commit bd2627efe9, reversing
changes made to 42ed551554.
This commit is contained in:
shokollm
2026-04-04 07:24:03 +00:00
parent 922858a81a
commit c005ee341a
3 changed files with 16 additions and 90 deletions

View File

@@ -210,31 +210,6 @@ class BountyService:
self._storage.update_bounty(room_id, bounty)
return True
def delete_bounties(
self, room_id: int, bounty_ids: list[int], user_id: int
) -> dict[int, str]:
"""Soft delete multiple bounties. Only admins can delete.
Returns a dict mapping bounty_id to result:
- "deleted": Successfully soft-deleted
- "not_found": Bounty does not exist
- "permission_denied": User is not admin
"""
results = {}
for bounty_id in bounty_ids:
bounty = self._storage.get_bounty(room_id, bounty_id)
if not bounty:
results[bounty_id] = "not_found"
continue
if not self.is_admin(room_id, user_id):
results[bounty_id] = "permission_denied"
continue
bounty.deleted_at = int(time.time())
self._storage.update_bounty(room_id, bounty)
results[bounty_id] = "deleted"
return results
class TrackingService:
"""Service for tracking bounty operations."""