diff options
Diffstat (limited to 'cmd/cashierd')
-rw-r--r-- | cmd/cashierd/main.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/cmd/cashierd/main.go b/cmd/cashierd/main.go index e482dde..61461a7 100644 --- a/cmd/cashierd/main.go +++ b/cmd/cashierd/main.go @@ -212,13 +212,17 @@ func main() { var authprovider auth.Provider switch config.Auth.Provider { case "google": - authprovider = google.New(&config.Auth) + authprovider, err = google.New(&config.Auth) case "github": - authprovider = github.New(&config.Auth) + authprovider, err = github.New(&config.Auth) default: log.Fatalln("Unknown provider %s", config.Auth.Provider) } + if err != nil { + log.Fatal(err) + } + ctx := &appContext{ cookiestore: sessions.NewCookieStore([]byte(config.Server.CookieSecret)), authprovider: authprovider, |