Skip to content

Commit

Permalink
fix: editing chat messages does not go through content sanity checks
Browse files Browse the repository at this point in the history
  • Loading branch information
julianlam committed Jul 6, 2020
1 parent d6c619c commit 9a6b87d
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/messaging/edit.js
Expand Up @@ -8,6 +8,7 @@ const sockets = require('../socket.io');

module.exports = function (Messaging) {
Messaging.editMessage = async (uid, mid, roomId, content) => {
await Messaging.checkContent(content);
const raw = await Messaging.getMessageField(mid, 'content');
if (raw === content) {
return;
Expand Down

0 comments on commit 9a6b87d

Please sign in to comment.