feat: 前端登录跳转问题
All checks were successful
Web Console Deploy (Vue 3 + Vite) / deploy (push) Successful in 1m10s
Backend Deploy (Go + Docker) / deploy (push) Successful in 1m44s

This commit is contained in:
zs
2026-03-03 01:33:12 +08:00
parent 235fc9c87f
commit c686d81d30
2 changed files with 7 additions and 3 deletions

View File

@@ -2,6 +2,7 @@ package handler
import (
"encoding/json"
"log"
"net/http"
"github.com/zs/InsightReply/internal/service"
@@ -29,7 +30,8 @@ func (h *UserHandler) Register(w http.ResponseWriter, r *http.Request) {
user, err := h.svc.Register(body.Email, body.Password, body.Identity)
if err != nil {
SendError(w, http.StatusInternalServerError, 5001, "Failed to register user")
log.Printf("[Register] Failed to register user %s: %v", body.Email, err)
SendError(w, http.StatusInternalServerError, 5001, "Failed to register user: "+err.Error())
return
}