Merge pull request #3348 from overleaf/revert-3298-jpa-re-land-mongoose-latest

Revert "[misc] re-land: remove mongojs and bump mongoose"

GitOrigin-RevId: 45a284435c88898d96769ab258651fb8d6d20ff5
This commit is contained in:
Jakob Ackermann
2020-11-02 15:57:41 +01:00
committed by Copybot
parent 6a837ce457
commit e249a2e5be
60 changed files with 671 additions and 454 deletions
@@ -15,7 +15,7 @@ const ProjectOptionsHandler = {
}
const conditions = { _id: projectId }
const update = { compiler }
Project.updateOne(conditions, update, {}, callback)
Project.update(conditions, update, {}, callback)
},
setImageName(projectId, imageName, callback) {
@@ -31,7 +31,7 @@ const ProjectOptionsHandler = {
}
const conditions = { _id: projectId }
const update = { imageName: settings.imageRoot + '/' + imageName }
Project.updateOne(conditions, update, {}, callback)
Project.update(conditions, update, {}, callback)
},
setSpellCheckLanguage(projectId, languageCode, callback) {
@@ -46,7 +46,7 @@ const ProjectOptionsHandler = {
}
const conditions = { _id: projectId }
const update = { spellCheckLanguage: languageCode }
Project.updateOne(conditions, update, {}, callback)
Project.update(conditions, update, {}, callback)
},
setBrandVariationId(projectId, brandVariationId, callback) {
@@ -55,13 +55,13 @@ const ProjectOptionsHandler = {
}
const conditions = { _id: projectId }
const update = { brandVariationId }
Project.updateOne(conditions, update, {}, callback)
Project.update(conditions, update, {}, callback)
},
unsetBrandVariationId(projectId, callback) {
const conditions = { _id: projectId }
const update = { $unset: { brandVariationId: 1 } }
Project.updateOne(conditions, update, {}, callback)
Project.update(conditions, update, {}, callback)
}
}