mirror of
https://github.com/Dvorinka/Trackeep.git
synced 2026-06-03 20:12:58 +00:00
feat(messages): implement integrated chat with voice/calls and tidy root go module
Add Discord-like messaging APIs, websocket realtime, smart suggestions, password vault flows, semantic indexing integration, and new /app/messages UI. Add typing indicators, advanced message search filters, voice notes, browser-local optional transcription, and WebRTC call signaling (offer/answer/ice/hangup). Clean root go.mod via go mod tidy and remove stale root go.sum.
This commit is contained in:
@@ -137,6 +137,11 @@ func AuthMiddleware() gin.HandlerFunc {
|
||||
}
|
||||
|
||||
authHeader := c.GetHeader("Authorization")
|
||||
if authHeader == "" {
|
||||
if tokenParam := c.Query("token"); tokenParam != "" {
|
||||
authHeader = "Bearer " + tokenParam
|
||||
}
|
||||
}
|
||||
if authHeader == "" {
|
||||
c.JSON(401, gin.H{"error": "Authorization header required"})
|
||||
c.Abort()
|
||||
@@ -230,6 +235,9 @@ func Register(c *gin.Context) {
|
||||
return
|
||||
}
|
||||
|
||||
// Provision messaging defaults (self chat, password vault, global channels).
|
||||
_ = ensureMessagingDefaults(db, user.ID)
|
||||
|
||||
// Generate JWT token
|
||||
token, err := GenerateJWT(user)
|
||||
if err != nil {
|
||||
|
||||
Reference in New Issue
Block a user