mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-28 21:13:20 -05:00
26f3f3e2e2
Migrate scripts folder to esm 1/x GitOrigin-RevId: 4a4bc9a161f144fdb40ce3f2a0a9313b36c6df81
20 lines
420 B
JavaScript
20 lines
420 B
JavaScript
import BatchedUpdateScript from '../scripts/helpers/batchedUpdate.mjs'
|
|
|
|
const { batchedUpdate } = BatchedUpdateScript
|
|
const tags = ['server-ce', 'server-pro', 'saas']
|
|
|
|
const migrate = async () => {
|
|
await batchedUpdate(
|
|
'users',
|
|
{ 'features.templates': { $exists: true } },
|
|
{ $unset: { 'features.templates': true } }
|
|
)
|
|
}
|
|
|
|
const rollback = async () => {}
|
|
|
|
export default {
|
|
tags,
|
|
migrate,
|
|
rollback,
|
|
}
|