mirror of
				https://github.com/NodeBB/NodeBB.git
				synced 2025-10-31 11:05:54 +01:00 
			
		
		
		
	removed sanitisation of chat message body, as messages are "parsed as a post" now.
This commit is contained in:
		| @@ -148,8 +148,6 @@ SocketModules.chats.send = function(socket, data, callback) { | |||||||
| 		return; | 		return; | ||||||
| 	} | 	} | ||||||
|  |  | ||||||
| 	var msg = S(data.message).stripTags().s; |  | ||||||
|  |  | ||||||
| 	var now = Date.now(); | 	var now = Date.now(); | ||||||
| 	socket.lastChatMessageTime = socket.lastChatMessageTime || 0; | 	socket.lastChatMessageTime = socket.lastChatMessageTime || 0; | ||||||
|  |  | ||||||
| @@ -177,7 +175,7 @@ SocketModules.chats.send = function(socket, data, callback) { | |||||||
| 				return callback(err || new Error('[[error:chat-restricted]]')); | 				return callback(err || new Error('[[error:chat-restricted]]')); | ||||||
| 			} | 			} | ||||||
|  |  | ||||||
| 			Messaging.addMessage(socket.uid, touid, msg, function(err, message) { | 			Messaging.addMessage(socket.uid, touid, data.message, function(err, message) { | ||||||
| 				if (err) { | 				if (err) { | ||||||
| 					return callback(err); | 					return callback(err); | ||||||
| 				} | 				} | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user