diff --git a/pkg/database/postgres.go b/pkg/database/postgres.go index ff4eb16..7025a97 100644 --- a/pkg/database/postgres.go +++ b/pkg/database/postgres.go @@ -71,7 +71,6 @@ func (p *postgresqlConnection) AddUserWithRelationToSource(ctx context.Context, } func (p *postgresqlConnection) AddSource(ctx context.Context, anthroveSource *graphModels.AnthroveSource) error { - source := utils.GraphConvertSource(anthroveSource) return postgres.CreateSourceNode(ctx, p.db, source) } diff --git a/pkg/models/graphModels/api.go b/pkg/models/graphModels/api.go deleted file mode 100644 index 7683097..0000000 --- a/pkg/models/graphModels/api.go +++ /dev/null @@ -1,20 +0,0 @@ -package graphModels - -type FavoriteRelations struct { - SourcesID string `json:"sources_id"` - Relations AnthrovePostRelationship `json:"relations"` -} - -type FavoritePost struct { - AnthrovePost AnthrovePost `json:"anthrove_post"` - Relations []FavoriteRelations `json:"relations"` -} - -type FavoriteList struct { - Posts []FavoritePost `json:"posts,omitempty"` -} - -type TagsWithFrequency struct { - Frequency int64 `json:"frequency"` - Tags AnthroveTag `json:"tags"` -} diff --git a/pkg/models/graphModels/post.go b/pkg/models/graphModels/post.go deleted file mode 100644 index 28caa38..0000000 --- a/pkg/models/graphModels/post.go +++ /dev/null @@ -1,8 +0,0 @@ -package graphModels - -import "git.dragse.it/anthrove/otter-space-sdk/pkg/models" - -type AnthrovePost struct { - PostID models.AnthrovePostID `json:"post_id"` - Rating models.Rating `json:"rating"` -} diff --git a/pkg/models/graphModels/relationships.go b/pkg/models/graphModels/relationships.go deleted file mode 100644 index 639966f..0000000 --- a/pkg/models/graphModels/relationships.go +++ /dev/null @@ -1,12 +0,0 @@ -package graphModels - -type AnthroveUserRelationship struct { - UserID string `json:"user_id"` - Username string `json:"username"` - ScrapeTimeInterval string `json:"scrape_time_interval"` - Source AnthroveSource `json:"source"` -} -type AnthrovePostRelationship struct { - PostID string `json:"post_id"` - Url string `json:"url"` -} diff --git a/pkg/models/graphModels/source.go b/pkg/models/graphModels/source.go deleted file mode 100644 index 5e3795b..0000000 --- a/pkg/models/graphModels/source.go +++ /dev/null @@ -1,7 +0,0 @@ -package graphModels - -type AnthroveSource struct { - DisplayName string `json:"display_name"` - Domain string `json:"domain"` - Icon string `json:"icon"` -} diff --git a/pkg/models/graphModels/tag.go b/pkg/models/graphModels/tag.go deleted file mode 100644 index 699a1fc..0000000 --- a/pkg/models/graphModels/tag.go +++ /dev/null @@ -1,6 +0,0 @@ -package graphModels - -type AnthroveTag struct { - Name string `json:"name"` - Type string `json:"type"` -} diff --git a/pkg/models/graphModels/user.go b/pkg/models/graphModels/user.go deleted file mode 100644 index 3b74a51..0000000 --- a/pkg/models/graphModels/user.go +++ /dev/null @@ -1,8 +0,0 @@ -package graphModels - -import "git.dragse.it/anthrove/otter-space-sdk/pkg/models" - -type AnthroveUser struct { - UserID models.AnthroveUserID `json:"user_id"` - Relationship []AnthroveUserRelationship `json:"relationship"` -}