merch-api/internal/user/handler.go
nquidox 081267a662
All checks were successful
/ Make image (push) Successful in 58s
get personal endpoint
2026-04-01 17:49:36 +03:00

31 lines
504 B
Go

package user
import (
"github.com/jackc/pgx/v5/pgxpool"
"merch-api/internal/common"
"merch-api/pkg/utils"
)
const pkgLogHeader string = "User |"
type Handler struct {
*service
controller *controller
}
type Deps struct {
DB *pgxpool.Pool
Utils utils.Utils
AuthDP common.AuthDataProvider
}
func New(deps Deps) *Handler {
r := newRepository(deps.DB)
s := newService(r, deps.Utils, deps.AuthDP)
c := newController(s, deps.Utils)
return &Handler{
service: s,
controller: c,
}
}