From 6d15d995633b269f42f6567f87c7bb90d667ff58 Mon Sep 17 00:00:00 2001 From: SoXX Date: Fri, 31 May 2024 15:05:04 +0200 Subject: [PATCH] chore(post): changed code layout Signed-off-by: SoXX --- pkg/graph/post.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/pkg/graph/post.go b/pkg/graph/post.go index d1d27c8..f08d75b 100644 --- a/pkg/graph/post.go +++ b/pkg/graph/post.go @@ -10,9 +10,9 @@ type Post interface { CreatePost(ctx context.Context, anthrovePost *models.AnthrovePost) error DeletePost(ctx context.Context, anthrovePost *models.AnthrovePost) error - // LinkPostWithSource establishes a link between a post and a source in the OtterSpace graph. - // It returns an error if the operation fails. - LinkPostWithSource(ctx context.Context, anthrovePostID models.AnthrovePostID, anthroveSourceDomain string, anthrovePostRelationship *models.AnthrovePostRelationship) error + // CheckPostNodeExistsBySourceID checks if a post node exists in the OtterSpace graph by its source ID. + // It returns the post if it exists, a boolean indicating whether the post was found, and an error if the operation fails. + CheckPostNodeExistsBySourceID(ctx context.Context, sourcePostID string) (*models.AnthrovePost, bool, error) // CheckPostNodeExistsByAnthroveID checks if a post node exists in the OtterSpace graph by its Anthrove ID. // It returns the post if it exists, a boolean indicating whether the post was found, and an error if the operation fails. @@ -22,7 +22,7 @@ type Post interface { // It returns the post if it exists, a boolean indicating whether the post was found, and an error if the operation fails. CheckPostNodeExistsBySourceURL(ctx context.Context, sourceUrl string) (*models.AnthrovePost, bool, error) - // CheckPostNodeExistsBySourceID checks if a post node exists in the OtterSpace graph by its source ID. - // It returns the post if it exists, a boolean indicating whether the post was found, and an error if the operation fails. - CheckPostNodeExistsBySourceID(ctx context.Context, sourcePostID string) (*models.AnthrovePost, bool, error) + // LinkPostWithSource establishes a link between a post and a source in the OtterSpace graph. + // It returns an error if the operation fails. + LinkPostWithSource(ctx context.Context, anthrovePostID models.AnthrovePostID, anthroveSourceDomain string, anthrovePostRelationship *models.AnthrovePostRelationship) error }