mirror of
https://github.com/volatiletech/authboss.git
synced 2025-09-16 09:06:20 +02:00
Group constants.
This commit is contained in:
@@ -8,8 +8,9 @@ import (
|
||||
"gopkg.in/authboss.v0"
|
||||
)
|
||||
|
||||
var (
|
||||
googleInfoEndpoint = `https://www.googleapis.com/userinfo/v2/me`
|
||||
const (
|
||||
googleInfoEndpoint = `https://www.googleapis.com/userinfo/v2/me`
|
||||
facebookInfoEndpoint = `https://graph.facebook.com/me?fields=name,email`
|
||||
)
|
||||
|
||||
type googleMeResponse struct {
|
||||
@@ -47,10 +48,6 @@ type facebookMeResponse struct {
|
||||
Name string `json:"name"`
|
||||
}
|
||||
|
||||
const (
|
||||
facebookInfoEndpoint = "https://graph.facebook.com/me?fields=name,email"
|
||||
)
|
||||
|
||||
// Facebook is a callback appropriate for use with Facebook's OAuth2 configuration.
|
||||
func Facebook(cfg oauth2.Config, token *oauth2.Token) (authboss.Attributes, error) {
|
||||
client := cfg.Client(oauth2.NoContext, token)
|
||||
|
Reference in New Issue
Block a user