Skip to content

Commit

Permalink
Merge branch 'improve/remove-omnichannel-queue-col' of github.com:Roc…
Browse files Browse the repository at this point in the history
…ketChat/Rocket.Chat into improve/remove-omnichannel-queue-col
  • Loading branch information
KevLehman committed Jun 16, 2022
2 parents 707eff5 + 7a7abc2 commit 1969af6
Showing 1 changed file with 7 additions and 4 deletions.
11 changes: 7 additions & 4 deletions apps/meteor/server/startup/migrations/v269.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,13 @@
import { MongoInternals } from 'meteor/mongo';

import { addMigration } from '../../lib/migrations';
import { Rooms } from '../../../app/models/server';

// Remove Deprecated Omnichannel Queue Collection
addMigration({
version: 269,
up() {
Rooms.tryDropIndex({ 'tokenpass.tokens.token': 1 });
Rooms.tryDropIndex({ tokenpass: 1 });
async up() {
// Remove collection
const { mongo } = MongoInternals.defaultRemoteCollectionDriver();
await mongo.db.dropCollection('rocketchat_omnichannel_queue');
},
});

0 comments on commit 1969af6

Please sign in to comment.