Poststore migration part3 (#15505)
* Migration completed * Order in translations file * Fix: lints * Trigger CI * Fix message key * Change mlog.Error for mlog.Warn * Fix imports * Adding translations needed for EE * Trigger CI * Fix merge with master Co-authored-by: Agniva De Sarker <agnivade@yahoo.co.in> Co-authored-by: Mattermod <mattermod@users.noreply.github.com>
Этот коммит содержится в:
коммит произвёл
GitHub
родитель
cd7d68effb
Коммит
8118cac350
@@ -84,7 +84,7 @@ func (s SearchPostStore) Update(newPost, oldPost *model.Post) (*model.Post, erro
|
||||
return post, err
|
||||
}
|
||||
|
||||
func (s *SearchPostStore) Overwrite(post *model.Post) (*model.Post, *model.AppError) {
|
||||
func (s *SearchPostStore) Overwrite(post *model.Post) (*model.Post, error) {
|
||||
post, err := s.PostStore.Overwrite(post)
|
||||
if err == nil {
|
||||
s.indexPost(post)
|
||||
@@ -131,7 +131,7 @@ func (s SearchPostStore) PermanentDeleteByChannel(channelID string) error {
|
||||
return err
|
||||
}
|
||||
|
||||
func (s SearchPostStore) searchPostsInTeamForUserByEngine(engine searchengine.SearchEngineInterface, paramsList []*model.SearchParams, userId, teamId string, page, perPage int) (*model.PostSearchResults, *model.AppError) {
|
||||
func (s SearchPostStore) searchPostsInTeamForUserByEngine(engine searchengine.SearchEngineInterface, paramsList []*model.SearchParams, userId, teamId string, page, perPage int) (*model.PostSearchResults, error) {
|
||||
if err := model.IsSearchParamsListValid(paramsList); err != nil {
|
||||
return nil, err
|
||||
}
|
||||
@@ -173,7 +173,7 @@ func (s SearchPostStore) searchPostsInTeamForUserByEngine(engine searchengine.Se
|
||||
return model.MakePostSearchResults(postList, matches), nil
|
||||
}
|
||||
|
||||
func (s SearchPostStore) SearchPostsInTeamForUser(paramsList []*model.SearchParams, userId, teamId string, page, perPage int) (*model.PostSearchResults, *model.AppError) {
|
||||
func (s SearchPostStore) SearchPostsInTeamForUser(paramsList []*model.SearchParams, userId, teamId string, page, perPage int) (*model.PostSearchResults, error) {
|
||||
for _, engine := range s.rootStore.searchEngine.GetActiveEngines() {
|
||||
if engine.IsSearchEnabled() {
|
||||
results, err := s.searchPostsInTeamForUserByEngine(engine, paramsList, userId, teamId, page, perPage)
|
||||
|
||||
Ссылка в новой задаче
Block a user