mirror of
https://iceshrimp.dev/limepotato/jormungandr-bite.git
synced 2024-11-27 04:17:51 -07:00
Fix bug
This commit is contained in:
parent
9a1fa024ce
commit
5c32223b6d
1 changed files with 7 additions and 6 deletions
|
@ -269,6 +269,8 @@ export default async (user: IUser, data: {
|
||||||
// Publish note to local and hybrid timeline stream
|
// Publish note to local and hybrid timeline stream
|
||||||
if (note.visibility != 'home') {
|
if (note.visibility != 'home') {
|
||||||
publishLocalTimelineStream(noteObj);
|
publishLocalTimelineStream(noteObj);
|
||||||
|
}
|
||||||
|
if (note.visibility == 'public') {
|
||||||
publishHybridTimelineStream(null, noteObj);
|
publishHybridTimelineStream(null, noteObj);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -281,9 +283,11 @@ export default async (user: IUser, data: {
|
||||||
|
|
||||||
if (note.visibility == 'specified') {
|
if (note.visibility == 'specified') {
|
||||||
data.visibleUsers.forEach(async u => {
|
data.visibleUsers.forEach(async u => {
|
||||||
stream(u._id, 'note', await pack(note, u, {
|
const n = await pack(note, u, {
|
||||||
detail: true
|
detail: true
|
||||||
}));
|
});
|
||||||
|
stream(u._id, 'note', n);
|
||||||
|
publishHybridTimelineStream(u._id, n);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -304,10 +308,7 @@ export default async (user: IUser, data: {
|
||||||
|
|
||||||
// Publish event to followers stream
|
// Publish event to followers stream
|
||||||
stream(following.followerId, 'note', noteObj);
|
stream(following.followerId, 'note', noteObj);
|
||||||
|
publishHybridTimelineStream(following.followerId, noteObj);
|
||||||
if (isRemoteUser(user)) {
|
|
||||||
publishHybridTimelineStream(following.followerId, noteObj);
|
|
||||||
}
|
|
||||||
} else {
|
} else {
|
||||||
//#region AP配送
|
//#region AP配送
|
||||||
// フォロワーがリモートユーザーかつ投稿者がローカルユーザーなら投稿を配信
|
// フォロワーがリモートユーザーかつ投稿者がローカルユーザーなら投稿を配信
|
||||||
|
|
Loading…
Reference in a new issue