auth
auth/grant.go
Update error strings, add ErrNo*Store errors. Update error strings to consistently begin with a lowercase letter and end without punctuation, as per the Go style guide. See https://code.google.com/p/go-wiki/wiki/CodeReviewComments#Error_Strings For each type of Store, add an ErrNo*Store error (e.g., ErrNoTokenStore) variable, to prepare for our Context type, which will throw these errors when a Store is used without being set.
1.1 --- a/grant.go Mon Sep 29 00:58:42 2014 -0400 1.2 +++ b/grant.go Wed Oct 15 23:22:19 2014 -0400 1.3 @@ -8,8 +8,9 @@ 1.4 ) 1.5 1.6 var ( 1.7 - ErrGrantNotFound = errors.New("Grant not found in GrantStore.") 1.8 - ErrGrantAlreadyExists = errors.New("Grant already exists in GrantStore.") 1.9 + ErrNoGrantStore = errors.New("no GrantStore was specified for the Context") 1.10 + ErrGrantNotFound = errors.New("grant not found in GrantStore") 1.11 + ErrGrantAlreadyExists = errors.New("grant already exists in GrantStore") 1.12 ) 1.13 1.14 type Grant struct {