MCPcopy Create free account
hub / github.com/Creatly/creatly-backend / GetPublishedById

Method GetPublishedById

internal/repository/modules_mongo.go:59–65  ·  view source on GitHub ↗
(ctx context.Context, moduleId primitive.ObjectID)

Source from the content-addressed store, hash-verified

57}
58
59func (r *ModulesRepo) GetPublishedById(ctx context.Context, moduleId primitive.ObjectID) (domain.Module, error) {
60 var module domain.Module
61
62 err := r.db.FindOne(ctx, bson.M{"_id": moduleId, "published": true}).Decode(&module)
63
64 return module, err
65}
66
67func (r *ModulesRepo) GetById(ctx context.Context, moduleId primitive.ObjectID) (domain.Module, error) {
68 var module domain.Module

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected