mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-10-30 18:46:01 +01:00 
			
		
		
		
	fix: federate out a Create(Note) instead of just the note... doi...
#12834
This commit is contained in:
		| @@ -223,7 +223,15 @@ activitypubApi.create.privateNote = enabledCheck(async (caller, { mid, messageOb | |||||||
| 	let targets = await messaging.getUidsInRoom(roomId, 0, -1); | 	let targets = await messaging.getUidsInRoom(roomId, 0, -1); | ||||||
| 	targets = targets.filter(uid => !utils.isNumber(uid)); // remote uids only | 	targets = targets.filter(uid => !utils.isNumber(uid)); // remote uids only | ||||||
|  |  | ||||||
| 	const payload = await activitypub.mocks.notes.private({ messageObj }); | 	const object = await activitypub.mocks.notes.private({ messageObj }); | ||||||
|  |  | ||||||
|  | 	const payload = { | ||||||
|  | 		id: `${object.id}#activity/create/${Date.now()}`, | ||||||
|  | 		type: 'Create', | ||||||
|  | 		to: object.to, | ||||||
|  | 		object, | ||||||
|  | 	}; | ||||||
|  |  | ||||||
| 	await activitypub.send('uid', messageObj.fromuid, targets, payload); | 	await activitypub.send('uid', messageObj.fromuid, targets, payload); | ||||||
| }); | }); | ||||||
|  |  | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user