mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-11-03 20:45:58 +01:00 
			
		
		
		
	fix: logic derp
This commit is contained in:
		@@ -59,7 +59,7 @@ inbox.update = async (req) => {
 | 
				
			|||||||
inbox.like = async (req) => {
 | 
					inbox.like = async (req) => {
 | 
				
			||||||
	const { actor, object } = req.body;
 | 
						const { actor, object } = req.body;
 | 
				
			||||||
	const { type, id } = await activitypub.helpers.resolveLocalId(object);
 | 
						const { type, id } = await activitypub.helpers.resolveLocalId(object);
 | 
				
			||||||
	if (type !== 'post' || await posts.exists(id)) {
 | 
						if (type !== 'post' || !(await posts.exists(id))) {
 | 
				
			||||||
		throw new Error('[[error:activitypub.invalid-id]]');
 | 
							throw new Error('[[error:activitypub.invalid-id]]');
 | 
				
			||||||
	}
 | 
						}
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user