mirror of
https://github.com/overleaf/overleaf.git
synced 2024-12-03 08:21:48 -05:00
17 lines
449 B
JavaScript
17 lines
449 B
JavaScript
|
const InstitutionsManager = require(
|
||
|
'../app/js/Features/Institutions/InstitutionsManager'
|
||
|
)
|
||
|
|
||
|
const institutionId = parseInt(process.argv[2])
|
||
|
if (isNaN(institutionId)) throw new Error('No institution id')
|
||
|
console.log('Upgrading users of institution', institutionId)
|
||
|
|
||
|
InstitutionsManager.upgradeInstitutionUsers(institutionId, function (error) {
|
||
|
if (error) {
|
||
|
console.log(error)
|
||
|
} else {
|
||
|
console.log('DONE 👌')
|
||
|
}
|
||
|
process.exit()
|
||
|
})
|