mirror of
https://github.com/Floriansylvain/RenewCMS.git
synced 2026-08-19 19:53:21 +02:00
18 lines
405 B
Go
18 lines
405 B
Go
package useCases
|
|
|
|
import (
|
|
"GoCMS/domain/gateways"
|
|
)
|
|
|
|
type DeleteArticleUseCase struct {
|
|
articleRepository gateways.IArticleRepository
|
|
}
|
|
|
|
func NewDeleteArticleUseCase(articleRepository gateways.IArticleRepository) *DeleteArticleUseCase {
|
|
return &DeleteArticleUseCase{articleRepository}
|
|
}
|
|
|
|
func (g *DeleteArticleUseCase) DeleteArticle(userId uint32) error {
|
|
return g.articleRepository.Delete(userId)
|
|
}
|