feat: return id
This commit is contained in:
@ -126,6 +126,7 @@ func (h *AuthHandler) login(w http.ResponseWriter, r *http.Request) {
|
|||||||
// fields required for UI in account selector, e.g. email, full name and avatar
|
// fields required for UI in account selector, e.g. email, full name and avatar
|
||||||
FullName string `json:"full_name"`
|
FullName string `json:"full_name"`
|
||||||
Email string `json:"email"`
|
Email string `json:"email"`
|
||||||
|
Id string `json:"id"`
|
||||||
// Avatar
|
// Avatar
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -134,6 +135,7 @@ func (h *AuthHandler) login(w http.ResponseWriter, r *http.Request) {
|
|||||||
RefreshToken: refreshToken,
|
RefreshToken: refreshToken,
|
||||||
FullName: user.FullName,
|
FullName: user.FullName,
|
||||||
Email: user.Email,
|
Email: user.Email,
|
||||||
|
Id: user.ID.String(),
|
||||||
// Avatar
|
// Avatar
|
||||||
}); err != nil {
|
}); err != nil {
|
||||||
web.Error(w, "failed to encode response", http.StatusInternalServerError)
|
web.Error(w, "failed to encode response", http.StatusInternalServerError)
|
||||||
|
Reference in New Issue
Block a user