diff options
Diffstat (limited to 'internal/api/client/mutes/mutesget.go')
| -rw-r--r-- | internal/api/client/mutes/mutesget.go | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/internal/api/client/mutes/mutesget.go b/internal/api/client/mutes/mutesget.go index 7fcbc2b44..76c31ebc6 100644 --- a/internal/api/client/mutes/mutesget.go +++ b/internal/api/client/mutes/mutesget.go @@ -23,7 +23,6 @@ import ( "github.com/gin-gonic/gin" apiutil "github.com/superseriousbusiness/gotosocial/internal/api/util" "github.com/superseriousbusiness/gotosocial/internal/gtserror" - "github.com/superseriousbusiness/gotosocial/internal/oauth" "github.com/superseriousbusiness/gotosocial/internal/paging" ) @@ -108,9 +107,12 @@ import ( // '500': // description: internal server error func (m *Module) MutesGETHandler(c *gin.Context) { - authed, err := oauth.Authed(c, true, true, true, true) - if err != nil { - apiutil.ErrorHandler(c, gtserror.NewErrorUnauthorized(err, err.Error()), m.processor.InstanceGetV1) + authed, errWithCode := apiutil.TokenAuth(c, + true, true, true, true, + apiutil.ScopeReadMutes, + ) + if errWithCode != nil { + apiutil.ErrorHandler(c, errWithCode, m.processor.InstanceGetV1) return } |
