(ctx context.Context, moduleId primitive.ObjectID)
| 57 | } |
| 58 | |
| 59 | func (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 | |
| 67 | func (r *ModulesRepo) GetById(ctx context.Context, moduleId primitive.ObjectID) (domain.Module, error) { |
| 68 | var module domain.Module |
nothing calls this directly
no outgoing calls
no test coverage detected