2024-10-01 05:53:36 -04:00
|
|
|
const Helpers = require('./lib/helpers')
|
2021-07-26 09:01:20 -04:00
|
|
|
|
2024-10-01 05:53:36 -04:00
|
|
|
exports.tags = ['saas']
|
2021-07-26 09:01:20 -04:00
|
|
|
|
|
|
|
const indexes = [
|
|
|
|
{
|
|
|
|
key: {
|
|
|
|
'overleaf.history.display': 1,
|
|
|
|
},
|
|
|
|
name: 'overleaf.history.display_1',
|
|
|
|
},
|
|
|
|
]
|
|
|
|
|
2024-10-01 05:53:36 -04:00
|
|
|
exports.migrate = async client => {
|
2021-07-26 09:01:20 -04:00
|
|
|
const { db } = client
|
|
|
|
await Helpers.addIndexesToCollection(db.projects, indexes)
|
|
|
|
}
|
|
|
|
|
2024-10-01 05:53:36 -04:00
|
|
|
exports.rollback = async client => {
|
2021-07-26 09:01:20 -04:00
|
|
|
const { db } = client
|
|
|
|
await Helpers.dropIndexesFromCollection(db.projects, indexes)
|
|
|
|
}
|