minor change

This commit is contained in:
yangzhouhan 2015-08-14 17:18:12 -07:00
parent 3df1dd419a
commit dd6b930e09
1 changed files with 1 additions and 2 deletions

View File

@ -520,8 +520,7 @@ func main() {
} }
opts = append(opts, grpc.WithPerRPCCredentials(jwtCreds)) opts = append(opts, grpc.WithPerRPCCredentials(jwtCreds))
} else if *testCase == "oauth2_token_creds" { } else if *testCase == "oauth2_token_creds" {
token := getToken() opts = append(opts, grpc.WithPerRPCCredentials(oauth.NewOauthAccess(getToken())))
opts = append(opts, grpc.WithPerRPCCredentials(oauth.NewOauthAccess(token)))
} }
} }
conn, err := grpc.Dial(serverAddr, opts...) conn, err := grpc.Dial(serverAddr, opts...)