Co-authored-by: MeiMei <30769358+mei23@users.noreply.github.com>
Co-authored-by: Satsuki Yanagi <17376330+u1-liquid@users.noreply.github.com>
This commit is contained in:
syuilo
2020-01-30 04:37:25 +09:00
committed by GitHub
parent a5955c1123
commit f6154dc0af
871 changed files with 26140 additions and 71950 deletions

View File

@@ -25,7 +25,7 @@ export default async function(follower: User, followee: User, requestId?: string
if (blocking != null) throw new Error('blocking');
if (blocked != null) throw new Error('blocked');
await FollowRequests.save({
const followRequest = await FollowRequests.save({
id: genId(),
createdAt: new Date(),
followerId: follower.id,
@@ -50,7 +50,9 @@ export default async function(follower: User, followee: User, requestId?: string
}).then(packed => publishMainStream(followee.id, 'meUpdated', packed));
// 通知を作成
createNotification(followee.id, follower.id, 'receiveFollowRequest');
createNotification(followee.id, follower.id, 'receiveFollowRequest', {
followRequestId: followRequest.id
});
}
if (Users.isLocalUser(follower) && Users.isRemoteUser(followee)) {