From c242a2b57a9fd2b477d9a50ea68990ccb50110c1 Mon Sep 17 00:00:00 2001 From: SoXX Date: Fri, 31 May 2024 16:05:27 +0200 Subject: [PATCH] refactor(model): changed types of model Signed-off-by: SoXX --- pkg/graph/post.go | 2 +- pkg/graph/source.go | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/pkg/graph/post.go b/pkg/graph/post.go index 5053858..054d124 100644 --- a/pkg/graph/post.go +++ b/pkg/graph/post.go @@ -27,5 +27,5 @@ type Post interface { CheckPostNodeExistsBySourceURL(ctx context.Context, sourceUrl string) (*models.AnthrovePost, bool, error) // LinkPostWithSource establishes a link between a post and a source in the OtterSpace graph. - LinkPostWithSource(ctx context.Context, anthrovePostID models.AnthrovePostID, anthroveSourceDomain string, anthrovePostRelationship *models.AnthrovePostRelationship) error + LinkPostWithSource(ctx context.Context, anthrovePostID models.AnthrovePostID, anthroveSourceDomain models.AnthroveSourceDomain, anthrovePostRelationship *models.AnthrovePostRelationship) error } diff --git a/pkg/graph/source.go b/pkg/graph/source.go index ddadc28..2d133d4 100644 --- a/pkg/graph/source.go +++ b/pkg/graph/source.go @@ -23,7 +23,7 @@ type Source interface { // GetSourceLinkForSpecifiedUser GetSourceLinkForUser retrieves the links between a user and a specific source in the OtterSpace graph. // It returns a map of source domains to user-source relationships, and an error if the operation fails. - GetSourceLinkForSpecifiedUser(ctx context.Context, anthroveUserID models.AnthroveUserID, sourceDisplayName string) (map[string]models.AnthroveUserRelationship, error) + GetSourceLinkForSpecifiedUser(ctx context.Context, anthroveUserID models.AnthroveUserID, sourceDisplayName models.AnthroveSourceDisplayName) (map[string]models.AnthroveUserRelationship, error) // GetAllSources returns a list of Sources in the database GetAllSources(ctx context.Context) ([]models.AnthroveSource, error)