1
0
mirror of https://git.boykissers.com/pawkey/pawkey-sk.git synced 2025-12-20 04:04:16 +00:00

fix: Boost count not decrementing on removal

This commit is contained in:
Mar0xy
2023-10-15 02:09:38 +02:00
parent 46f1882123
commit 4359a13946

View File

@@ -68,6 +68,10 @@ export class NoteDeleteService {
await this.notesRepository.decrement({ id: note.replyId }, 'repliesCount', 1);
}
if (note.renoteId && note.renote?.userId != user.id && note.text == null && !note.hasPoll && (note.fileIds == null || note.fileIds.length === 0)) {
await this.notesRepository.decrement({ id: note.renoteId }, 'renoteCount', 1);
}
if (!quiet) {
this.globalEventService.publishNoteStream(note.id, 'deleted', {
deletedAt: deletedAt,