auth
auth/context.go
Drop RemoveToken, test RevokeToken for refresh tokens. The RemoveToken function was never actually used, and there's no reason to use it. Tokens are revoked, not removed. So I deleted it. And while I was updating the tests, I finally inserted the test for revoking a refresh token, mainly to get rid of that damn TODO.
1.1 --- a/context.go Mon Jan 19 04:24:22 2015 -0500 1.2 +++ b/context.go Mon Jan 19 06:01:51 2015 -0500 1.3 @@ -309,15 +309,6 @@ 1.4 return c.tokens.saveToken(token) 1.5 } 1.6 1.7 -// RemoveToken removes the Token identified by the passed token string from the tokenStore associated 1.8 -// with the Context. 1.9 -func (c Context) RemoveToken(token string) error { 1.10 - if c.tokens == nil { 1.11 - return ErrNoTokenStore 1.12 - } 1.13 - return c.tokens.removeToken(token) 1.14 -} 1.15 - 1.16 // RevokeToken revokes the Token identfied by the passed token string from the tokenStore associated 1.17 // with the context. If refresh is true, the token input should be compared against the refresh tokens, 1.18 // not the access tokens.