Add common type for oauth authorization errors

This commit is contained in:
Alexander Menzhinsky
2017-02-01 16:42:59 +03:00
parent aef4195493
commit 30c334a2b8
5 changed files with 37 additions and 28 deletions
+2 -6
View File
@@ -2,7 +2,6 @@ package social
import (
"encoding/json"
"errors"
"fmt"
"net/http"
@@ -21,11 +20,8 @@ type SocialGithub struct {
}
var (
ErrMissingTeamMembership = errors.New("User not a member of one of the required teams")
)
var (
ErrMissingOrganizationMembership = errors.New("User not a member of one of the required organizations")
ErrMissingTeamMembership = &Error{"User not a member of one of the required teams"}
ErrMissingOrganizationMembership = &Error{"User not a member of one of the required organizations"}
)
func (s *SocialGithub) Type() int {