(_ context.Context, poolID string)
| 63 | } |
| 64 | |
| 65 | func (s *sqlDatabase) GetPoolByID(_ context.Context, poolID string) (params.Pool, error) { |
| 66 | preloadList := []string{ |
| 67 | "Tags", |
| 68 | "Instances", |
| 69 | "Enterprise", |
| 70 | "Enterprise.Endpoint", |
| 71 | "Organization", |
| 72 | "Organization.Endpoint", |
| 73 | "Repository", |
| 74 | "Repository.Endpoint", |
| 75 | "Template", |
| 76 | } |
| 77 | pool, err := s.getPoolByID(s.conn, poolID, preloadList...) |
| 78 | if err != nil { |
| 79 | return params.Pool{}, fmt.Errorf("error fetching pool by ID: %w", err) |
| 80 | } |
| 81 | return s.sqlToCommonPool(pool) |
| 82 | } |
| 83 | |
| 84 | func (s *sqlDatabase) DeletePoolByID(_ context.Context, poolID string) (err error) { |
| 85 | pool, err := s.getPoolByID(s.conn, poolID) |
no test coverage detected