diff options
Diffstat (limited to 'internal/api/client/account/accountverify.go')
-rw-r--r-- | internal/api/client/account/accountverify.go | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/internal/api/client/account/accountverify.go b/internal/api/client/account/accountverify.go index 6b8d1f92c..1da0251a3 100644 --- a/internal/api/client/account/accountverify.go +++ b/internal/api/client/account/accountverify.go @@ -19,10 +19,12 @@ package account import ( - "github.com/sirupsen/logrus" "net/http" + "github.com/sirupsen/logrus" + "github.com/gin-gonic/gin" + "github.com/superseriousbusiness/gotosocial/internal/api" "github.com/superseriousbusiness/gotosocial/internal/oauth" ) @@ -60,6 +62,11 @@ func (m *Module) AccountVerifyGETHandler(c *gin.Context) { return } + if _, err := api.NegotiateAccept(c, api.JSONAcceptHeaders...); err != nil { + c.JSON(http.StatusNotAcceptable, gin.H{"error": err.Error()}) + return + } + acctSensitive, err := m.processor.AccountGet(c.Request.Context(), authed, authed.Account.ID) if err != nil { l.Debugf("error getting account from processor: %s", err) |