initial commit

This commit is contained in:
maotovisk 2025-08-06 16:04:04 -03:00
parent 9baa0fab25
commit fc46164556
14 changed files with 243 additions and 0 deletions

21
internal/services/link.go Normal file
View file

@ -0,0 +1,21 @@
package services
import (
"context"
"maot-shortner/internal/domain"
"maot-shortner/internal/repositories"
)
type LinkService struct {
repo repositories.LinkRepository
}
func NewLinkService(repo repositories.LinkRepository) *LinkService {
return &LinkService{
repo: repo,
}
}
func (s *LinkService) GetLinks(ctx context.Context) ([]*domain.Link, error) {
return s.repo.GetLinks(ctx)
}