Merge pull request #2332 from AllenZMC/improve_search

Clear conflict between variable `delete` and builtin function
This commit is contained in:
karmada-bot 2022-08-05 09:26:02 +08:00 committed by GitHub
commit c77f416960
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 2 additions and 2 deletions

View File

@ -149,12 +149,12 @@ func (os *OpenSearch) delete(obj interface{}) {
return
}
delete := opensearchapi.DeleteRequest{
deleteRequest := opensearchapi.DeleteRequest{
Index: indexName,
DocumentID: string(us.GetUID()),
}
resp, err := delete.Do(context.Background(), os.client)
resp, err := deleteRequest.Do(context.Background(), os.client)
if err != nil {
klog.Errorf("cannot delete: %v", err)
return