mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-11-15 14:43:46 +01:00
remove logging, fix query
This commit is contained in:
@@ -30,14 +30,14 @@ success = 0
|
|||||||
fixDangling = (doc_id, callback) ->
|
fixDangling = (doc_id, callback) ->
|
||||||
# look up project id from doc id
|
# look up project id from doc id
|
||||||
db.docs.find {_id:ObjectId(doc_id)}, {project_id:1}, (err, result) ->
|
db.docs.find {_id:ObjectId(doc_id)}, {project_id:1}, (err, result) ->
|
||||||
console.log "doc_id", doc_id, "err", err, "result", result
|
#console.log "doc_id", doc_id, "err", err, "result", result
|
||||||
if err?
|
if err?
|
||||||
errored++
|
errored++
|
||||||
return callback()
|
return callback()
|
||||||
if !result? or result.length == 0
|
if !result? or result.length == 0
|
||||||
missing++
|
missing++
|
||||||
return callback()
|
return callback()
|
||||||
project_id = result[0]
|
project_id = result[0].project_id
|
||||||
console.log "found project_id", project_id, "for doc_id", doc_id
|
console.log "found project_id", project_id, "for doc_id", doc_id
|
||||||
url = "http://localhost:#{options.port}/project/#{project_id}/doc/#{doc_id}/flush"
|
url = "http://localhost:#{options.port}/project/#{project_id}/doc/#{doc_id}/flush"
|
||||||
if options.force
|
if options.force
|
||||||
|
|||||||
Reference in New Issue
Block a user