1
0

improvements.

This commit is contained in:
piuvas
2024-12-23 20:42:21 -03:00
parent 83460279c0
commit 94c3a71e49
5 changed files with 40 additions and 10 deletions
@@ -70,12 +70,18 @@ class BubbleTimelineChannel extends Channel {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.renote, this.user.id);
note.renote.myReaction = myRenoteReaction;
}
if (note.renote && note.renote.reply) {
if (Object.keys(note.renote.reply.reactions).length > 0) {
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.renote.reply, this.user.id);
note.renote.reply.myReaction = myReplyReaction;
}
}
}
if (this.user && note.reply) {
if (Object.keys(note.reply.reactions).length > 0) {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myRenoteReaction;
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myReplyReaction;
}
}
@@ -65,12 +65,18 @@ class GlobalTimelineChannel extends Channel {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.renote, this.user.id);
note.renote.myReaction = myRenoteReaction;
}
if (note.renote && note.renote.reply) {
if (Object.keys(note.renote.reply.reactions).length > 0) {
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.renote.reply, this.user.id);
note.renote.reply.myReaction = myReplyReaction;
}
}
}
if (this.user && note.reply) {
if (Object.keys(note.reply.reactions).length > 0) {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myRenoteReaction;
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myReplyReaction;
}
}
@@ -86,12 +86,18 @@ class HomeTimelineChannel extends Channel {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.renote, this.user.id);
note.renote.myReaction = myRenoteReaction;
}
if (note.renote && note.renote.reply) {
if (Object.keys(note.renote.reply.reactions).length > 0) {
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.renote.reply, this.user.id);
note.renote.reply.myReaction = myReplyReaction;
}
}
}
if (this.user && note.reply) {
if (Object.keys(note.reply.reactions).length > 0) {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myRenoteReaction;
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myReplyReaction;
}
}
@@ -104,12 +104,18 @@ class HybridTimelineChannel extends Channel {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.renote, this.user.id);
note.renote.myReaction = myRenoteReaction;
}
if (note.renote && note.renote.reply) {
if (Object.keys(note.renote.reply.reactions).length > 0) {
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.renote.reply, this.user.id);
note.renote.reply.myReaction = myReplyReaction;
}
}
}
if (this.user && note.reply) {
if (Object.keys(note.reply.reactions).length > 0) {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myRenoteReaction;
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myReplyReaction;
}
}
@@ -75,12 +75,18 @@ class LocalTimelineChannel extends Channel {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.renote, this.user.id);
note.renote.myReaction = myRenoteReaction;
}
if (note.renote && note.renote.reply) {
if (Object.keys(note.renote.reply.reactions).length > 0) {
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.renote.reply, this.user.id);
note.renote.reply.myReaction = myReplyReaction;
}
}
}
if (this.user && note.reply) {
if (Object.keys(note.reply.reactions).length > 0) {
const myRenoteReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myRenoteReaction;
const myReplyReaction = await this.noteEntityService.populateMyReaction(note.reply, this.user.id);
note.reply.myReaction = myReplyReaction;
}
}