mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-10-31 11:05:54 +01:00 
			
		
		
		
	fix: closes #11697, remove min attribute from rep thresholds
This commit is contained in:
		| @@ -292,11 +292,12 @@ Messaging.canMessageRoom = async (uid, roomId) => { | ||||
| }; | ||||
|  | ||||
| async function checkReputation(uid) { | ||||
| 	if (meta.config['min:rep:chat'] > 0) { | ||||
| 		const reputation = await user.getUserField(uid, 'reputation'); | ||||
| 		if (meta.config['min:rep:chat'] > reputation) { | ||||
| 			throw new Error(`[[error:not-enough-reputation-to-chat, ${meta.config['min:rep:chat']}]]`); | ||||
| 		} | ||||
| 	if (meta.config['reputation:disabled']) { | ||||
| 		return; | ||||
| 	} | ||||
| 	const reputation = await user.getUserField(uid, 'reputation'); | ||||
| 	if (meta.config['min:rep:chat'] > reputation) { | ||||
| 		throw new Error(`[[error:not-enough-reputation-to-chat, ${meta.config['min:rep:chat']}]]`); | ||||
| 	} | ||||
| } | ||||
|  | ||||
|   | ||||
		Reference in New Issue
	
	Block a user