mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-07 20:31:06 -05:00
just get doc_id for quick check to see if it exists
This commit is contained in:
parent
7adc67d13a
commit
ffd1aa0ca4
1 changed files with 1 additions and 1 deletions
|
@ -101,7 +101,7 @@ module.exports = DocManager =
|
|||
callback null, modified, rev
|
||||
|
||||
deleteDoc: (project_id, doc_id, callback = (error) ->) ->
|
||||
DocManager.getDoc project_id, doc_id, { version: false }, (error, doc) ->
|
||||
DocManager.getDoc project_id, doc_id, { _id: true }, (error, doc) ->
|
||||
return callback(error) if error?
|
||||
return callback new Errors.NotFoundError("No such project/doc to delete: #{project_id}/#{doc_id}") if !doc?
|
||||
MongoManager.markDocAsDeleted project_id, doc_id, callback
|
||||
|
|
Loading…
Reference in a new issue