Commit Graph

1311 Commits

Author SHA1 Message Date
luna f5922db52f Merge branch 'fix/permission-hierarchy' into 'master'
Make permission checks aware of role hierarchy

Closes #110

See merge request litecord/litecord!76
2021-08-31 02:57:05 +00:00
Luna dd10d7f996 s/user_id/member_id 2021-08-30 23:54:13 -03:00
Luna 1819075137 properly unsubscribe member when being removed 2021-08-30 23:52:35 -03:00
Luna 43e34cde3a fix typo in sql statement 2021-08-30 23:39:53 -03:00
Luna 70cd40966d fix typo on sql query 2021-08-30 23:37:02 -03:00
Luna 36a69ad8cb fix typo 2021-08-30 23:22:54 -03:00
Luna 0c14473a95 checks: validate when target or user is an owner 2021-08-30 23:18:28 -03:00
Luna 4c2bbe89a1 remove unused function 2021-08-30 22:59:33 -03:00
Luna cb23d972c6 add targets to guild_perm_check calls 2021-08-30 22:51:53 -03:00
Luna e2b150ee21 cheks: refactor target member 2021-08-30 22:43:23 -03:00
Luna 6c1a73233b checks: add target_member_id to guild_perm_check 2021-08-30 22:13:20 -03:00
Luna 7374091dec gateway: only send payload if ws exists 2021-08-30 00:21:39 -03:00
Luna 6e9ddd89f8 relationships: move self-self check to make_friend 2021-08-30 00:16:32 -03:00
Luna f05b807f60 move dispatching logic to GatewayState
this makes gateway states have correct data for resuming
2021-08-30 00:09:34 -03:00
Luna d16a893d84 fix nick updates on lazy guilds 2021-08-29 22:59:18 -03:00
Luna 6cb92ae7f2 gateway: support v6 ready.read_state 2021-08-29 21:26:04 -03:00
Luna 221c2f5c6c refactor websocket properties name 2021-08-29 21:25:15 -03:00
Luna 0271b37de4 gateway: make user_guild_settings repr depend on gw version 2021-08-29 21:15:54 -03:00
Luna 81de11a8cf gateway: update identify schema 2021-08-29 21:03:25 -03:00
Luna cc70beb87a user.billing: fill plan_id with correct plan ids 2021-08-29 19:36:26 -03:00
Luna 4c1823c8b7 user.billing: add better stub for subscription.items 2021-08-29 19:32:19 -03:00
Luna 60b7216aac user.billing: add stub to subscription.items 2021-08-29 19:29:53 -03:00
Luna b4b54379e1 update OP class 2021-08-29 19:25:23 -03:00
Luna 9d557e2817 add stub for op 24 2021-08-29 19:19:33 -03:00
Luna 331d316feb gateway: add debug logging for received messages 2021-08-29 19:19:18 -03:00
Luna 55f86393f8 gateway: fix Request Guild Members 2021-08-29 19:18:59 -03:00
Luna eb88651424 add stubs for some routes 2021-08-29 18:08:21 -03:00
Luna 9cdb79b084 store: add subscription-plan stubs for specific SKUs 2021-08-29 17:09:57 -03:00
Luna d2cca438ab users: add stub entitlements 2021-08-29 17:09:17 -03:00
Luna 587aac380f add store blueprint 2021-08-29 16:47:15 -03:00
Luna f0c0b8e9c2 fix typo 2021-08-29 16:37:44 -03:00
Luna 59e1056604 users: add 'with_mutual_guilds' argument support 2021-08-29 16:20:05 -03:00
Luna 0a429ee47e add support for user.bio, user.accent_color CRUD 2021-08-29 15:53:00 -03:00
Luna 266bb0a07b migrations: add 11_user_bio_and_accent_color 2021-08-29 15:52:49 -03:00
Luna 122798c567 schemas: add bio and accent_color 2021-08-29 15:52:28 -03:00
Luna 2a71d9f131 add applications stub blueprint 2021-08-29 15:05:46 -03:00
Luna 1818f93019 add stickers stub blueprint 2021-08-29 14:59:37 -03:00
Luna 1a95e95303 fix typo 2021-08-29 13:00:29 -03:00
Luna 495f0d4b8c messages: fix before_messages array pointing to earliest message 2021-08-29 12:58:47 -03:00
Luna ead5346713 billing: add stub for country-code route 2021-08-29 12:00:10 -03:00
Luna ae26f20705 storage: add stub for emoji.available 2021-08-29 11:48:05 -03:00
Luna b66e5e0443 fix typo 2021-08-29 01:34:25 -03:00
Luna e55ada44a8 gateway: allow self user in ready.users 2021-08-29 01:33:11 -03:00
Luna ae5c0bd0e3 gateway: allow nullable seq but invalidate if received 2021-08-29 01:32:03 -03:00
Luna a2f892192d messages: fix ordering of "around" result 2021-08-29 01:27:06 -03:00
Luna 3ed0ff8176 fix typing on message_search internal function 2021-08-29 01:21:04 -03:00
Luna 92dba16237 add proper support for "around" parameter 2021-08-29 01:17:46 -03:00
Luna 0b20ba1283 storage: fix another code path for members 2021-08-29 00:32:56 -03:00
Luna ec5fa255c6 storage: fix _member_dict 2021-08-29 00:31:02 -03:00
Luna a0bc36d319 storage: fix nick field on member_basic 2021-08-29 00:29:12 -03:00