MCPcopy Create free account
hub / github.com/darjun/go-daily-lib / CallbackHandler

Function CallbackHandler

goth/github/main.go:51–58  ·  view source on GitHub ↗
(w http.ResponseWriter, r *http.Request)

Source from the content-addressed store, hash-verified

49}
50
51func CallbackHandler(w http.ResponseWriter, r *http.Request) {
52 user, err := gothic.CompleteUserAuth(w, r)
53 if err != nil {
54 fmt.Fprintln(w, err)
55 return
56 }
57 ptTemplate.ExecuteTemplate(w, "home.tpl", user)
58}
59
60func main() {
61 githubProvider := github.New(clientKey, clientSecret, "http://localhost:8080/auth/github/callback")

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected