Isaac Janzen
a3693fec58
FEATURE: Allow drafts to be deleted via the API ( #21148 )
...
This PR adds the ability to destroy drafts for a passed user via the API. This was not possible before as this action was reserved for only your personal drafts.
If a user is an admin and calls the `#destroy` action from the API they are able to destroy a draft for a passed user. A user can be targeted by passed either their:
- username
- external_id (for SSO)
to the request.
In the case you attempt to destroy a non-personal draft and
- You are not an admin
- You do not access the `#destroy` action via the API
you will raise a `Discourse::InvalidAccess` (403) and will not succeed in destroying the draft.
2023-04-19 14:41:45 -05:00
..
2023-04-18 14:32:18 +08:00
2023-04-13 15:38:54 +08:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-03-13 19:33:26 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-04-19 14:41:45 -05:00
2023-02-16 10:47:01 +00:00
2023-02-28 14:31:59 +02:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-25 13:50:33 +02:00
2023-02-03 12:17:52 +01:00
2023-01-09 11:49:28 +00:00
2023-03-08 12:38:58 -03:00
2023-04-12 09:25:06 +08:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2022-07-28 10:27:38 +08:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-03-02 16:40:53 +01:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-02-06 11:55:52 -07:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-02-06 14:35:05 -05:00
2023-04-17 22:53:50 +05:30
2023-04-05 10:52:18 +10:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-02-17 18:56:25 +01:00
2023-03-14 11:42:11 +01:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-02-13 09:24:47 +11:00
2023-01-09 11:49:28 +00:00
2023-03-20 13:51:39 -05:00
2023-01-09 11:49:28 +00:00
2023-03-31 02:18:57 +08:00
2023-01-09 11:49:28 +00:00
2023-03-08 15:27:17 +10:00
2023-01-09 11:49:28 +00:00
2023-01-09 11:49:28 +00:00
2023-02-15 09:13:19 +00:00
2023-01-09 11:49:28 +00:00
2023-01-30 22:42:47 +00:00
2023-03-13 08:09:38 +08:00
2023-01-09 11:49:28 +00:00
2023-01-16 19:16:17 +02:00
2023-01-09 11:49:28 +00:00