7 Commits

Author SHA1 Message Date
5d72643390
Add is_owner decorator and owner checks (#81) 2025-06-15 15:23:52 -06:00
97273ce655
Format with black 2025-06-10 18:26:23 -06:00
60a183742a
Updates Python version requirements and refactors hybrid commands
Lowers minimum Python requirement from 3.11 to 3.10 to increase compatibility while updating CI to use Python 3.13 for testing.

Extracts hybrid command functionality into a separate module to improve code organization and reduce complexity in the main commands module.

Updates test timeouts and dependency versions to ensure reliable test execution and modern package compatibility.
2025-06-10 16:39:12 -06:00
81ea79a94d
Refactor: Move permission calculation to Channel model
The _compute_permissions helper function has been simplified by delegating the complex permission calculation logic to a new channel.permissions_for(member) method.

This refactoring encapsulates the permission logic within the Channel model, where it belongs. It removes duplicate and complex code from the command decorator, improving maintainability and separation of concerns.

The tests for requires_permissions have been updated to mock the new permissions_for method, resulting in cleaner tests that are no longer concerned with the internal implementation details of how permissions are calculated.
2025-06-10 16:05:33 -06:00
61222e1df7
Fix target ID assignment in Channel permissions and add guild_id to test Channel class 2025-06-10 16:00:24 -06:00
e9375a5a36
Implement requires_permissions decorator (#22)
* Add permissions check decorator

* Refactor command decorator and add permission computation logic
2025-06-10 15:54:00 -06:00
7c7cb4137c
Initial commit 2025-06-09 22:25:14 -06:00