mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-06-02 05:41:33 +02:00
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:
@@ -32,13 +32,13 @@ module.exports = {
|
||||
lastUpdated: lastUpdatedAt || new Date().getTime(),
|
||||
lastUpdatedBy
|
||||
}
|
||||
return Project.updateOne(conditions, update, {}, callback)
|
||||
return Project.update(conditions, update, {}, callback)
|
||||
},
|
||||
|
||||
markAsOpened(project_id, callback) {
|
||||
const conditions = { _id: project_id }
|
||||
const update = { lastOpened: Date.now() }
|
||||
return Project.updateOne(conditions, update, {}, function(err) {
|
||||
return Project.update(conditions, update, {}, function(err) {
|
||||
if (callback != null) {
|
||||
return callback()
|
||||
}
|
||||
@@ -48,7 +48,7 @@ module.exports = {
|
||||
markAsInactive(project_id, callback) {
|
||||
const conditions = { _id: project_id }
|
||||
const update = { active: false }
|
||||
return Project.updateOne(conditions, update, {}, function(err) {
|
||||
return Project.update(conditions, update, {}, function(err) {
|
||||
if (callback != null) {
|
||||
return callback()
|
||||
}
|
||||
@@ -58,7 +58,7 @@ module.exports = {
|
||||
markAsActive(project_id, callback) {
|
||||
const conditions = { _id: project_id }
|
||||
const update = { active: true }
|
||||
return Project.updateOne(conditions, update, {}, function(err) {
|
||||
return Project.update(conditions, update, {}, function(err) {
|
||||
if (callback != null) {
|
||||
return callback()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user