fix: rename AddListItem => CreateListItem
This commit is contained in:
@@ -26,7 +26,7 @@ type ListRepository interface {
|
||||
CreateList(ctx context.Context, name string, userIDs []string) (*List, error)
|
||||
AddUserToList(ctx context.Context, listID string, userID string) error
|
||||
RemoveUserFromList(ctx context.Context, listID string, userID string) error
|
||||
AddListItem(ctx context.Context, listID string, title string) (*ListItem, error)
|
||||
CreateListItem(ctx context.Context, listID string, title string) (*ListItem, error)
|
||||
UpdateListItem(ctx context.Context, listItemID string, title string, isCompleted bool) error
|
||||
}
|
||||
|
||||
|
||||
@@ -82,7 +82,7 @@ func (r *ListRepo) RemoveUserFromList(ctx context.Context, listID string, userID
|
||||
return nil
|
||||
}
|
||||
|
||||
func (r *ListRepo) AddListItem(ctx context.Context, listID string, title string) (*domain.ListItem, error) {
|
||||
func (r *ListRepo) CreateListItem(ctx context.Context, listID string, title string) (*domain.ListItem, error) {
|
||||
l := &domain.ListItem{Title: title}
|
||||
|
||||
err := r.db.QueryRowContext(ctx,
|
||||
|
||||
Reference in New Issue
Block a user