package svc

import (
	"backend/internal/config"
	"backend/pkg/permission/domain/usecase"
	"backend/pkg/permission/repository"
	uc "backend/pkg/permission/usecase"
	"github.com/zeromicro/go-zero/core/stores/redis"
)

func NewTokenUC(c *config.Config, rds *redis.Redis) usecase.TokenUseCase {
	return uc.MustTokenUseCase(uc.TokenUseCaseParam{
		TokenRepo: repository.MustTokenRepository(repository.TokenRepositoryParam{
			Redis: rds,
		}),
		Config: c,
	})
}
