diff --git a/app/post.go b/app/post.go index 7ad072943d..447fef6bb7 100644 --- a/app/post.go +++ b/app/post.go @@ -473,7 +473,7 @@ func DeletePost(postId string) (*model.Post, *model.AppError) { esInterface := einterfaces.GetElasticsearchInterface() if esInterface != nil && *utils.Cfg.ElasticSearchSettings.EnableIndexing { - go esInterface.DeletePost(post.Id) + go esInterface.DeletePost(post) } InvalidateCacheForChannelPosts(post.ChannelId) diff --git a/einterfaces/elasticsearch.go b/einterfaces/elasticsearch.go index b824821463..011b259b22 100644 --- a/einterfaces/elasticsearch.go +++ b/einterfaces/elasticsearch.go @@ -9,7 +9,7 @@ type ElasticsearchInterface interface { Start() *model.AppError IndexPost(post *model.Post, teamId string) *model.AppError SearchPosts(channels *model.ChannelList, searchParams []*model.SearchParams) ([]string, *model.AppError) - DeletePost(postId string) *model.AppError + DeletePost(post *model.Post) *model.AppError TestConfig(cfg *model.Config) *model.AppError PurgeIndexes() *model.AppError }