mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
fix: id on 1b12 announces
This commit is contained in:
@@ -50,7 +50,7 @@ async function announce(id, activity) {
|
||||
winston.info(`[activitypub/inbox.announce(1b12)] Announcing ${activity.type} to followers of cid ${cid}`);
|
||||
await Promise.all([activity, activity.object].map(async (object) => {
|
||||
await activitypub.send('cid', cid, followers, {
|
||||
id: `${id}#activity/announce/${Date.now()}`,
|
||||
id: `${nconf.get('url')}/post/${encodeURIComponent(id)}#activity/announce/${Date.now()}`,
|
||||
type: 'Announce',
|
||||
to: [`${nconf.get('url')}/category/${cid}/followers`],
|
||||
cc: [actor, activitypub._constants.publicAddress],
|
||||
|
||||
@@ -179,7 +179,7 @@ activitypubApi.create.note = enabledCheck(async (caller, { pid, post }) => {
|
||||
setTimeout(() => { // Delay sending to avoid potential race condition
|
||||
Promise.all([payload, payload.object].map(async (object) => {
|
||||
await activitypub.send('cid', cid, followers, {
|
||||
id: `${object.object ? object.object.id : object.id}#activity/announce/${Date.now()}`,
|
||||
id: `${nconf.get('url')}/post/${encodeURIComponent(object.object ? object.object.id : object.id)}#activity/announce/${Date.now()}`,
|
||||
type: 'Announce',
|
||||
to: [activitypub._constants.publicAddress],
|
||||
cc: [`${nconf.get('url')}/category/${cid}/followers`],
|
||||
|
||||
Reference in New Issue
Block a user