(_ context.Context, contentID string)
| 155 | } |
| 156 | |
| 157 | func (s *Search) DeleteContent(_ context.Context, contentID string) error { |
| 158 | if s.Client == nil { |
| 159 | return configuredErr |
| 160 | } |
| 161 | |
| 162 | index := s.Client.Index(s.Config.IndexName) |
| 163 | if s.Config.Async { |
| 164 | _, err := index.DeleteDocument(contentID) |
| 165 | return err |
| 166 | } else { |
| 167 | resp, err := index.DeleteDocument(contentID) |
| 168 | if err != nil { |
| 169 | return err |
| 170 | } |
| 171 | return waitForTask(s.Client, resp) |
| 172 | } |
| 173 | } |
| 174 | |
| 175 | func (s *Search) RegisterSyncer(ctx context.Context, syncer plugin.SearchSyncer) { |
| 176 | s.syncer = syncer |
nothing calls this directly
no test coverage detected