The communications platform that puts data protection first.
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 
Rocket.Chat/server/startup/migrations/v071.js

12 lines
417 B

import { Migrations } from '../../../app/migrations';
import { Messages } from '../../../app/models';
Migrations.add({
version: 71,
up() {
// Removes the reactions on messages which are the system type "rm" ;)
Messages.find({ t: 'rm', reactions: { $exists: true, $not: { $size: 0 } } }, { t: 1 }).forEach(function(message) {
Messages.update({ _id: message._id }, { $set: { reactions: [] } });
});
},
});