fix characters not updating on edit post and (hopefully) the bug preventing post deletions sometimes.
continuous-integration/drone/push Build is passing

This commit is contained in:
2021-07-26 20:15:51 +02:00
parent a606b79736
commit 67d6161c3b
2 changed files with 13 additions and 5 deletions
+7 -2
View File
@@ -267,9 +267,14 @@ func (r *postRepository) Delete(ctx context.Context, post models.Post) error {
return err
}
_ = q.GenerateLogTSVector(ctx, post.LogID)
err = tx.Commit()
if err != nil {
return err
}
return tx.Commit()
_ = psqlcore.New(r.db).GenerateLogTSVector(ctx, post.LogID)
return nil
}
func (r *postRepository) post(post psqlcore.SelectPostRow) *models.Post {