Skip to content

Commit

Permalink
legacy
Browse files Browse the repository at this point in the history
  • Loading branch information
Aeneas Rekkas (arekkas) committed Jun 23, 2016
1 parent b395fe0 commit 5c3f89a
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions oauth/provider/facebook/facebook.go
Original file line number Diff line number Diff line change
Expand Up @@ -55,14 +55,14 @@ func (d *facebook) FetchSession(code string) (Session, error) {
return nil, err
}

var acc map[string]interface{}
if err = res.Decode(&acc); err != nil {
return nil, err
}

return &DefaultSession{
RemoteSubject: fmt.Sprintf("%s", res.Get("id")),
Extra: acc,
Extra: map[string]interface{}{
"email": fmt.Sprintf("%s", res.Get("email")),
"id": fmt.Sprintf("%s", res.Get("id")),
"first_name": fmt.Sprintf("%s", res.Get("first_name")),
"last_name": fmt.Sprintf("%s", res.Get("last_name")),
},
}, nil
}

Expand Down

0 comments on commit 5c3f89a

Please sign in to comment.