From 46373e765702a203bfcb576c9d3639314ef4965f Mon Sep 17 00:00:00 2001 From: techknowlogick Date: Sat, 4 May 2019 11:45:34 -0400 Subject: Hash App token (#6724) --- routers/api/v1/user/app.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'routers/api/v1/user') diff --git a/routers/api/v1/user/app.go b/routers/api/v1/user/app.go index ef53e95d8b..d9716f419a 100644 --- a/routers/api/v1/user/app.go +++ b/routers/api/v1/user/app.go @@ -37,9 +37,9 @@ func ListAccessTokens(ctx *context.APIContext) { apiTokens := make([]*api.AccessToken, len(tokens)) for i := range tokens { apiTokens[i] = &api.AccessToken{ - ID: tokens[i].ID, - Name: tokens[i].Name, - Sha1: tokens[i].Sha1, + ID: tokens[i].ID, + Name: tokens[i].Name, + TokenLastEight: tokens[i].TokenLastEight, } } ctx.JSON(200, &apiTokens) @@ -81,9 +81,9 @@ func CreateAccessToken(ctx *context.APIContext, form api.CreateAccessTokenOption return } ctx.JSON(201, &api.AccessToken{ - Name: t.Name, - Sha1: t.Sha1, - ID: t.ID, + Name: t.Name, + Token: t.Token, + ID: t.ID, }) } -- cgit v1.2.3