summaryrefslogtreecommitdiff
path: root/internal/api/client
diff options
context:
space:
mode:
authorLibravatar nicole mikołajczyk <git@mkljczk.pl>2025-07-04 15:29:27 +0200
committerLibravatar kim <gruf@noreply.codeberg.org>2025-07-04 15:29:27 +0200
commit79914bdbf7677b5c708cc3431af611df2c4a46b2 (patch)
tree05c611eb8d115f6b0e9b960a42b99f50e925c8f5 /internal/api/client
parent[docs] Document STARTTLS behavior (#4301) (diff)
downloadgotosocial-79914bdbf7677b5c708cc3431af611df2c4a46b2.tar.xz
[bugfix] set correct scope for StatusFavePOSTHandler (#4310)
> **OAuth:** User token + `write:favourites` https://docs.joinmastodon.org/methods/statuses/#favourite Signed-off-by: nicole mikołajczyk <git@mkljczk.pl> Reviewed-on: https://codeberg.org/superseriousbusiness/gotosocial/pulls/4310 Reviewed-by: kim <gruf@noreply.codeberg.org> Co-authored-by: nicole mikołajczyk <git@mkljczk.pl> Co-committed-by: nicole mikołajczyk <git@mkljczk.pl>
Diffstat (limited to 'internal/api/client')
-rw-r--r--internal/api/client/statuses/statusfave.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/api/client/statuses/statusfave.go b/internal/api/client/statuses/statusfave.go
index 54d717ddd..592eb86b2 100644
--- a/internal/api/client/statuses/statusfave.go
+++ b/internal/api/client/statuses/statusfave.go
@@ -47,7 +47,7 @@ import (
//
// security:
// - OAuth2 Bearer:
-// - write:statuses
+// - write:favourites
//
// responses:
// '200':
@@ -69,7 +69,7 @@ import (
func (m *Module) StatusFavePOSTHandler(c *gin.Context) {
authed, errWithCode := apiutil.TokenAuth(c,
true, true, true, true,
- apiutil.ScopeWriteStatuses,
+ apiutil.ScopeWriteFavourites,
)
if errWithCode != nil {
apiutil.ErrorHandler(c, errWithCode, m.processor.InstanceGetV1)