feat: bundle frontend with API executable

This commit is contained in:
Sam 2022-06-17 00:00:52 +02:00
parent 57c7a0f4de
commit 6c9ebf1d08
13 changed files with 105 additions and 16 deletions

View file

@ -1,7 +1,6 @@
package auth
import (
"fmt"
"net/http"
"os"
@ -85,13 +84,13 @@ func (s *Server) discordCallback(w http.ResponseWriter, r *http.Request) error {
return err
}
fmt.Println(token)
render.JSON(w, r, discordCallbackResponse{
HasAccount: true,
Token: token,
User: &u,
})
return nil
} else if err != db.ErrUserNotFound { // internal error
return err
}