Files
website/internal/handlers/account/messages/list.go
2025-10-31 11:57:39 +00:00

25 lines
504 B
Go

// Package accountMessageHandler
// Path: /internal/handlers/account/messages
// File: list.go
// ToDo: helpers for reading getting messages shouldn't really be here. ---
package accountMessageHandler
import (
"github.com/gin-gonic/gin"
)
func mustUserID(c *gin.Context) int64 {
if v, ok := c.Get("userID"); ok {
if id, ok2 := v.(int64); ok2 {
return id
}
}
// Fallback for stubs:
return 1
}
type strconvNumErr struct{}
func (e *strconvNumErr) Error() string { return "invalid number" }