ad repo
This commit is contained in:
parent
99e750646e
commit
7e45dd493f
2 changed files with 8 additions and 1 deletions
|
|
@ -13,3 +13,10 @@ type gotoNoteResult struct {
|
|||
type GotoNoteHandler struct{
|
||||
noteRepo repositories.INoteRepository
|
||||
}
|
||||
|
||||
func(h *GotoNoteHandler) Handle(command gotoNoteCommand) (gotoNoteResult, error) {
|
||||
note, err := h.noteRepo.GetBySlug(command.Slug)
|
||||
if err != nil {
|
||||
return gotoNoteResult{}, err
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,7 +17,7 @@ type INoteRepository interface {
|
|||
|
||||
type noteRepository struct{}
|
||||
|
||||
func NewNoteRepository() INoteRepository {
|
||||
func NewNoteRepository(persistence.ReadContext) INoteRepository {
|
||||
return ¬eRepository{}
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue